BUG: OpenResultset Doesn't Fire QueryComplete in Class Module (172239)
The information in this article applies to:
- Microsoft Visual Basic Enterprise Edition for Windows 5.0
- Microsoft Visual Basic Enterprise Edition for Windows 6.0
This article was previously published under Q172239 SYMPTOMS
Program code in the QueryComplete event procedure of a rdoConnection object
will not execute if you use the OpenResultset method to execute a query in
a class module.
RESOLUTION
The resolution to this problem is to call DoEvents function after opening
the resultset. For example:
Set rs = cn.OpenResultset("select * from Authors", _
rdOpenKeyset, rdConcurValues)
DoEvents
If you use the OpenResultset method with the rdAsyncEnable option, you need
to use the following code to workaround the problem:
Set rs = cn.OpenResultset("select * from Authors", _
rdOpenKeyset, rdConcurValues, rdAsyncEnable)
While rs.StillExecuting
DoEvents
Wend
DoEvents
STATUS
Microsoft is researching this problem and will post new information here in
the Microsoft Knowledge Base as it becomes available.
Modification Type: | Major | Last Reviewed: | 11/7/2003 |
---|
Keywords: | kbbug KB172239 |
---|
|