www.webdeveloper.com
Results 1 to 4 of 4

Thread: Either BOF or EOF is True, or the current record has been deleted.

  1. #1
    Join Date
    Jul 2012
    Posts
    5

    Either BOF or EOF is True, or the current record has been deleted.

    Hi,

    I'm trying to update a database, when I am getting the error:
    Code:
    ADODB.Field
    
    error '800a0bcd'
    
    Either BOF or EOF is True, or the current record has been deleted.
    Requested operation requires a current record.
    
    /admin/edit_product.asp, line 139
    The line in question is:

    Code:
    <%
    Dim doc1, doc2, doc3, doc4, doc5
    
    doc1=(rs_prod_details.Fields.Item("prod_doc1").Value) - line 139
    doc2=(rs_prod_details.Fields.Item("prod_doc2").Value)
    doc3=(rs_prod_details.Fields.Item("prod_doc3").Value)
    doc4=(rs_prod_details.Fields.Item("prod_doc4").Value)
    doc5=(rs_prod_details.Fields.Item("prod_doc5").Value)
    %>
    Not really sure on what the problem could be here. Can anybody offer any assistance?
    Thanks in advance.

  2. #2
    Join Date
    Sep 2011
    Posts
    59
    you trying to read value from recordset, but your recordset is empty....
    you should always chaeck for end of file property on recordset as below
    Code:
    <%
    Dim doc1, doc2, doc3, doc4, doc5
    if not rs_prod_details.EOF then
    doc1=(rs_prod_details.Fields.Item("prod_doc1").Value) - line 139
    doc2=(rs_prod_details.Fields.Item("prod_doc2").Value)
    doc3=(rs_prod_details.Fields.Item("prod_doc3").Value)
    doc4=(rs_prod_details.Fields.Item("prod_doc4").Value)
    doc5=(rs_prod_details.Fields.Item("prod_doc5").Value)
    end if
    %>

  3. #3
    Join Date
    Jul 2012
    Posts
    5
    Hi,

    Many thanks for your reply. I've put this in place and the error still persists. The page is a form which is pre-populated, saving the details back into an Access database. Any more ideas please? Thanks

  4. #4
    Join Date
    Sep 2011
    Posts
    59
    Are you still have error on the same line?
    try just add before line with error
    Code:
    response.write rs_prod_details.EOF
    response.flush
    response.end
    if should print on screen false
    if it is
    change code to
    Code:
    response.write rs_prod_details("prod_doc1")
    response.flush
    response.end
    and make sure it is printed value

Thread Information

Users Browsing this Thread

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

Posting Permissions

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



Recent Articles