Solved

rs.Close, Runtime Error 3219 (VB6)

Posted on 2004-08-09
2
5,430 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

This is an explanation of a simple data model to help parse a JSON feed
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 fourth video of the Xpdf series, we discuss and demonstrate the PDFinfo utility, which retrieves the contents of a PDF's Info Dictionary, as well as some other information, including the page count. We show how to isolate the page count in a…
With the power of JIRA, there's an unlimited number of ways you can customize it, use it and benefit from it. With that in mind, there's bound to be things that I wasn't able to cover in this course. With this summary we'll look at some places to go…

696 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