+ Reply to Thread
Results 1 to 4 of 4

run time error '3021'; Either BOF or EOF is True, or the current record has been deleted.

  1. #1
    Forum Contributor
    Join Date
    03-01-2014
    Location
    Mysore
    MS-Off Ver
    Excel 2007
    Posts
    379

    run time error '3021'; Either BOF or EOF is True, or the current record has been deleted.

    run time error '3021';

    Either BOF or EOF is True, or the current record has been deleted.
    Requested operation requires a current record.

    Here i am trying to import data from the mysql database in ascending order to excelsheet (data is importing to excelsheet but it is not updating data in excel sheet whenever i run update in my excelsheet its shows that error Please Help me out

    Please Login or Register  to view this content.
    Please Login or Register  to view this content.

  2. #2
    Valued Forum Contributor
    Join Date
    09-21-2011
    Location
    Birmingham UK
    MS-Off Ver
    Excel 2003/7/10
    Posts
    2,188

    Re: run time error '3021'; Either BOF or EOF is True, or the current record has been dele

    Is it the client server? Also, do you get anything after this line

    rs.Open "select * from " & InputBox("Update Data"), dbconn, adOpenStatic, adLockOptimistic

    is there anything in the recordset?
    Hope this helps

    Sometimes its best to start at the beginning and learn VBA & Excel.

    Please dont ask me to do your work for you, I learnt from Reading books, Recording, F1 and Google and like having all of this knowledge in my head for the next time i wish to do it, or wish to tweak it.
    Available for remote consultancy work PM me

  3. #3
    Forum Guru romperstomper's Avatar
    Join Date
    11-04-2008
    Location
    A1
    MS-Off Ver
    Most
    Posts
    12,302

    Re: run time error '3021'; Either BOF or EOF is True, or the current record has been dele

    You should always test if the recordset's BOF or EOF property is true after you perform a Find operation (depending on which way you search). It would also be better to use MoveFirst before each Find, or use Filter instead.
    Remember what the dormouse said
    Feed your head

  4. #4
    Forum Contributor
    Join Date
    03-01-2014
    Location
    Mysore
    MS-Off Ver
    Excel 2007
    Posts
    379

    Re: run time error '3021'; Either BOF or EOF is True, or the current record has been dele

    yes in my record set having data in mysql server
    i have multiple batches in each batch multiple records i am just downloading data from batch and editing and updating data
    i have downloaded data from the mysql database into excelsheet in ascending order after editing in the excelsheet i am just updating data in the mysql database

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Runtime error 3021 Either BOF or EOF is true or the current record has been deleted.
    By aman1234 in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 12-19-2011, 01:52 PM
  2. How to record current time, without vba
    By susato in forum Excel General
    Replies: 2
    Last Post: 11-02-2010, 02:42 PM
  3. Error 3021: Either EoF or BoF is True.
    By NBVC in forum Excel Programming / VBA / Macros
    Replies: 32
    Last Post: 04-26-2010, 12:42 PM
  4. Error "Record is Deleted"
    By LilyMarie in forum Access Tables & Databases
    Replies: 2
    Last Post: 03-09-2009, 06:42 AM
  5. [SOLVED] Blocking Error 3021 No current record
    By dbl in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 09-11-2005, 09:05 AM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1