Solved

rs.Close, Runtime Error 3219 (VB6)

Posted on 2004-08-09
2
5,509 Views
Last Modified: 2012-06-27
Sorry guys, these are my last remaining points. In my program I have the code:
Private Sub Form_Load()
rs.Close
rs.Open "select * from UserNames where UserName = '" & gstUserName & "'"
rs.Fields!Grade = TeacherGrade
rs.Close <<< operation not allowed in this context, runtime error 3219
rs.Open TeacherGrade
rs.MoveFirst
Do Until rs.EOF
List1.AddItem rs.Fields!NameGrade
rs.MoveNext
Loop
End Sub

Any suggestions? and no this isn't a school project =P
0
Comment
Question by:Masterpip
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 18

Accepted Solution

by:
tusharashah earned 25 total points
ID: 11752012
Try "Rs.Update" or "Rs.CancelUpdate" before you close the recordset....

-tushar
0
 
LVL 16

Expert Comment

by:JohnBPrice
ID: 11755465
tusharashah is right, if you try to close a recordset which has an update pending, you get that error.
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Whether you’re a college noob or a soon-to-be pro, these tips are sure to help you in your journey to becoming a programming ninja and stand out from the crowd.
Today, the web development industry is booming, and many people consider it to be their vocation. The question you may be asking yourself is – how do I become a web developer?
In this fifth video of the Xpdf series, we discuss and demonstrate the PDFdetach utility, which is able to list and, more importantly, extract attachments that are embedded in PDF files. It does this via a command line interface, making it suitable …
Six Sigma Control Plans

729 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question