Microsoft KB Archive/301497

= FIX: The adAsyncExecute Flag Fails with VFPODBC After You Install MDAC 2.6 =

Article ID: 301497

Article Last Modified on 9/26/2005

-

APPLIES TO


 * Microsoft Open Database Connectivity Driver for Visual FoxPro 5.0
 * Microsoft Open Database Connectivity Driver for Visual FoxPro 1.0
 * Microsoft Open Database Connectivity Driver for Visual FoxPro 2.0
 * Microsoft Open Database Connectivity Driver for Visual FoxPro 3.0
 * Microsoft Open Database Connectivity Driver for Visual FoxPro 4.0
 * Microsoft Data Access Components 2.6
 * Microsoft Data Access Components 2.6 Service Pack 1

-



This article was previously published under Q301497



SYMPTOMS
After you install Microsoft Data Access Components (MDAC) version 2.6 or 2.6 Service Pack 1 (SP1), the ODBC Driver for Visual FoxPro no longer supports the adAsyncExecute flag. When you try to use this flag from ActiveX Data Objects (ADO), you receive the following error message on the client:

Current provider does not support asynchronous execution.



RESOLUTION
To resolve this problem, obtain the latest service pack for Microsoft Data Access Components 2.6. For additional information, click the following article number to view the article in the Microsoft Knowledge Base:

300635 INFO: How to Obtain the Latest MDAC 2.6 Service Pack

The English version of this fix should have the following file attributes or later:   Date         Version       Size     File name     Platform -  25-Jun-2001  2.61.7625.0   311,568  Msdasql.dll   x86 25-Jun-2001 2.61.7625.0    16,384  Msdasqlr.dll  x86 25-Jun-2001 2.61.7625.0    94,480  Msdatl3.dll   x86 25-Jun-2001 2.61.7625.0    24,848  Msdatt.dll    x86



STATUS
Microsoft has confirmed that this is a problem in the Microsoft products that are listed at the beginning of this article. This problem was first corrected in Microsoft Data Access Components 2.6 Service Pack 2.



MORE INFORMATION
To reproduce the problem, run the following Microsoft Visual Basic for Applications (VBA) code: Sub VFPAsyncFailTest Dim conn As ADODB.Connection Dim rs As ADODB.recordset ' Open connection to VFPODBC from ADO. Set conn = New ADODB.Connection conn.Open &quot;Provider=MSDASQL;&quot; & _ &quot;DRIVER=Microsoft FoxPro VFP Driver (*.dbf);&quot; & _ &quot;BackgroundFetch=No;Exclusive=No;&quot; & _ &quot;SourceType=DBF;SourceDB=C:\;&quot; ' Drop and re-create a test table. On Error Resume Next conn.Execute &quot;drop table filename.dbf&quot; On Error GoTo 0 conn.Execute &quot;create table filename.dbf (f1 c(10))&quot; conn.Execute &quot;insert into filename.dbf (f1) values ('Some Data...')&quot; ' Open table normally, which works OK here. Set rs = conn.Execute(&quot;select * from filename.dbf&quot;,, adCmdText) Debug.Print rs.Fields(&quot;f1&quot;).value rs.Close Set rs = Nothing ' Use adAsyncExecute to open. Error occurs here. Set rs = conn.Execute(&quot;select * from filename.dbf&quot;,, _                          adCmdText + adAsyncExecute) rs.Close Set rs = Nothing conn.Close Set conn = Nothing End Sub

Keywords: kbbug kbfix kbqfe kbmdac260sp2fix kbhotfixserver KB301497

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.