Visual Basic 6.0 translation

Thursday, November 29, 2012

Visual Basic Online Course - Run-time error '3021' : Either BOF or EOF is True, or the current record has been deleted.

Visual Basic Online Course

Run-time error '3021' : Either BOF or EOF is True, or the current record has been deleted.
Case :
In Visual Basic 6.0 project with Database (e.g: MS-Access 2003) table, while trying to navigate through records you get the following error message.
Error No. :
Error description :
Either BOF or EOF is True, or the current record has been deleted.
Requested operation requires a current record
Solution :


  1. im getting same error while updating and deleting the data,,pls help

  2. im getting the same error while updating and deleting the record set,,pls help

  3. The solution has already been posted in the Tip above .... Isn't it helping ?

  4. An impressive share! I've just forwarded this onto a friend who was doing a little homework on this.
    And he in fact ordered me breakfast due to the fact that I discovered it for him...

    lol. So allow me to reword this.... Thanks for the meal!!
    But yeah, thanx for spending the time to talk about this matter here on your web site.

    My homepage :: DarrelXSaborido

  5. Excellent way of explaining, and pleasant paragraph to get information regarding my presentation focus, which i am going to convey in academy.

    Here is my webpage :: DouglassRGearan

  6. I am extremely inspired along with your writing skills as smartly as with the format in your weblog.

    Is this a paid theme or did you customize it yourself?

    Anyway stay up the nice high quality writing, it's uncommon to peer a great blog like
    this one nowadays..

    my website EvelyneKWiedenheft

  7. I was suggested this blog by way of my cousin. I'm now not positive whether or
    not this post is written by way of him as no one else know such particular
    approximately my difficulty. You're wonderful!
    Thank you!

    my homepage; AnamariaKTenny

  8. You have made some decent points there. I checked on the web
    for more information about the issue and found most
    individuals will go along with your views on this web site.

    Check out my blog: DewayneLOare

  9. Heya i am for the first time here. I came across this board and I find It
    truly helpful & it helped me out much. I am hoping to offer something again and aid others like you aided me.

    Also visit my page CristiAMaroney

  10. I've been exploring for a bit for any high-quality articles or weblog posts on this sort of space .
    Exploring in Yahoo I at last stumbled upon this web site.
    Studying this info So i am glad to exhibit that I have an incredibly good
    uncanny feeling I came upon just what I needed.
    I so much surely will make sure to don?t disregard this web site and provides it
    a look regularly.

    Also visit my page :: AdrienYMckeirnan

  11. Hey! Would you mind if I share your blog with my myspace group?
    There's a lot of folks that I think would really enjoy your content.
    Please let me know. Cheers

    My website - AgustinHBrandly

  12. I face to same problem
    here source code,,,,,

    Dim con As New ADODB.Connection
    Dim rs As New ADODB.Recordset
    Dim str As String

    Private Sub addbtn_Click()
    End Sub

    Private Sub Combo1_Click()
    If Combo1.Text = "Computer Science" Then
    Combo2.AddItem "M.C.E"
    Combo2.AddItem "B.S.C"
    Combo2.AddItem "B.S.C(IT)"
    ElseIf Combo1.Text = "Electrical Engineering" Then
    Combo2.AddItem "B.TECH (EE)"
    Combo2.AddItem "M.TECH (EE)"
    ElseIf Combo1.Text = "Civil Engineering" Then
    Combo2.AddItem "B.TECH (CE)"
    Combo2.AddItem "M.TECH (CE)"
    End If
    End Sub

    Private Sub Form_Load()
    con.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=E:\VB6 Tuto\ST\stdata.mdb;Persist Security Info=False"
    rs.Open "Select * from ProfileDB", con, adOpenDynamic, adLockPessimistic

    Combo1.AddItem "Computer Science"
    Combo1.AddItem "Electrical Engineering"
    Combo1.AddItem "Civil Engineering"
    End Sub

    Private Sub savebtn_Click()
    rs.Fields("Roll_No").Value = Text1.Text
    rs.Fields("Name").Value = Text2.Text
    rs.Fields("DOB").Value = DTPicker1.Value
    If Option1.Value = True Then
    rs.Fields("Gender") = Option1.Caption
    rs.Fields("Gender") = Option2.Caption
    End If
    rs.Fields("Dept").Value = Combo1.Text
    rs.Fields("Course").Value = Combo2.Text
    rs.Fields("Address") = Text3.Text
    rs.Fields("Photo").Value = str
    MsgBox "Data save successfully", vbInformation

    End Sub

    Private Sub uploadbtn_Click()
    CommonDialog1.Filter = "Jpeg|*.jpg"
    str = CommonDialog1.FileName
    Picture1.Picture = LoadPicture(str)
    End Sub

    1. Solution is posted above already :

      'E.g: Moving to next record
      'Make sure your table is not empty
      If RS.RecordCount = 0 Then Exit Sub
      'Make sure the Absolute Position of the record's cursor is at
      'the right position, If not then Exit Sub
      'If the Absolute Position reached the last record then Exit Sub.
      If RS.AbsolutePosition = Val(RS.RecordCount) Then
      Exit Sub
      End If
      'Navigate [MoveNext]
      Text1.Text = RS!FieldName1
      Text2.Text = RS!FieldName2

  13. But My datbase(access 2007) is empty

  14. same code as (sarur abhi) Sir but my database is empty so what i write for this

  15. sir i need ur help code is same but my database is empty


visual basic 6 source code says (Hi)

Visual Basic Online Course

vb6 (63) Application Development (45) Visual Basic Online Course (45) Online Visual Basic Course (44) Visual Basic Help (44) Visual Basic Programming (42) IT Jobs (39) VB6 developer (38) Visual Basic Course (38) Visual Basic 6.0 (26) Microsoft Visual Basic 6.0 (25) VB6.0 (24) Visual Basic Programmers (24) vb 6.0 (24) visual basic programming tutorial (19) Third lesson (16) Source code download for Visual Basic 6.0 (14) Source code for Visual Basic 6.0 (10) visual basic tutorial (9) Visual Basic 6 (5) Visual Basic Courses (5) Lesson 3 (4) VB 0.6 - TreeView control (4) VB 0.6 With TreeView Control (4) VB6 Course (3) Create ActiveX (2) How to automate MS-Access from Visual Basic 6.0 (2) Add controls at runtime (1) Back up your Database (1) Change ActiveX icon (1) Change screen resolution (1) Create FTP (1) Crystal Reports 4.6 (1) Crystl32.ocx could not be loaded (1) DataGrid Columns re-size (1) Date Calculation (1) DateAdd Function (1) DateDiff function (1) FTP (1) Marquee Title Bar (1) Marquee VB 6.0 TitleBar (1) Method 'Action' of object 'CrystalCtrl' Failed (1) Microsoft Access with Visual Basic 6.0 (1) OpenSchema method (1) Save File Using CommonDilog (1) Track Database path (1) VB 0.6 - Registry (1) VB 0.6 With Registry Editor (1) VB 6.0 Access (1) VB 6.0 OOP (1) VB6 Access2003 ADO Like % (1) VB6 Add Date (1) VB6 Add Time (1) VB6 Date calculation (1) VB6 Subtract Date (1) Visual Basic Remote (1) Win7 (1) Windows7 (1) ms access networking details (1) remote Visual Basic DB (1) rounded and transparent forms (1) vb 0.6 style (1) vb 6.0 Remote Database (1)