Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Error No. -2147217887 Microsoft ODBC
Message
From
11/01/2001 03:16:40
 
 
To
All
General information
Forum:
Visual Basic
Category:
Database DAO/RDO/ODBC/ADO
Title:
Error No. -2147217887 Microsoft ODBC
Miscellaneous
Thread ID:
00462093
Message ID:
00462093
Views:
64
I am not understand, how come the below codes will occuring the error no. -2147217887 Microsoft ODBC Visual Foxpro Driver Invalid Parameters Number!

Is there something wrong in the ConnectionString? or may be the other else?

Dim cnData as ADODB.Connection
Dim rs as ADODB.Recordset
Dim mABCData as String

mABCData = app.path &"\ABC.DBC"
mConnectionString = "Driver={Microsoft Visual FoxPro Driver};UID=;PWD=;SourceDB=" & mABCData & ";SourceType=DBC;Exclusive=No;BackgroundFetch=Yes;Collate=Machine;Null=Yes;Deleted=Yes;"

cnData.ConnectionString = mConnectionString
cnData.ConnectionTimeout = 30
cnData.CursorLocation = adUseClient
cnData.Open

rsPAC.Open mSQL, MDIABC.cnData, adOpenKeyset, adLockOptimistic
rsPAC.MoveLast
If optSetup1.Value = True Then
rsPAC!BODC1 = chkOTC.Value
End If
If optSetup2.Value = True Then
rsPAC!BODC2 = chkOTC.Value
End If
For mOption = 1 To 2
For mPAC = 0 To 23
mPulseField = IIf(optSetup1.Value = True, "U", "A") & "P" & Trim(Str(mOption)) & PadToString(mPAC, 2)
mCostField = IIf(optSetup1.Value = True, "U", "A") & "C" & Trim(Str(mOption)) & PadToString(mPAC, 2)
If mOption = 1 Then
rs(mPulseField) = TDBGrid1.Columns(1).Text
rs(mCostField) = TDBGrid1.Columns(2).Text
Else
rs(mPulseField) = TDBGrid1.Columns(3).Text
rs(mCostField) = TDBGrid1.Columns(4).Text
End If
Next mPAC
Next mOption
rs.Update
rs.Close

TQ very very much

Best regards
Winan
Reply
Map
View

Click here to load this message in the networking platform