H
Herb B
Below code runs fine on about 10 laptops with windows xp pro sp2.
Code is snippet from an excel vba macro.
However, on just 1 laptop, we get following error message:
Error # -2147221164 was generated by Provider Class not registered
Error occurs on this line below:
adoRS1.Open strSQL1, adoCN, adOpenDynamic, adLockOptimistic
We've verified mdac is at 2.8 and all xp and office 2002 service packs
applied.
Not sure how to debug or figure out. Using oledb, so odbc trace didnt work.
Any ideas?
TIA.
======================================
Set adoCN = New ADODB.Connection
' ADO Connections for SQL Server
With adoCN
.Open "Provider=SQLOLEDB;" & _
"Data Source=xxx.xx.x.xx;" & _ ' IP address has
been changed from working IP.....
"Initial Catalog=dbFP_Summary;" & _
"User Id=fpsummaryrw;" & _
"Password=fpsummaryrw"
On Error GoTo ErrorHandler
End With
strSQL1 = "Select * From tbl_ESM_estimates Where " & _
"CR_Number = '" & strCRNum & "' And " & _
"System_ID = '" & strSystemID & "' And " & _
"TNC_Level = '" & strTNCLevel & "' "
strAudit = "tbl_ESM_estimates_Audit"
Set adoRS1 = New ADODB.Recordset
Set adoRS2 = New ADODB.Recordset
adoRS1.Open strSQL1, adoCN, adOpenDynamic, adLockOptimistic
adoRS2.Open strAudit, adoCN, adOpenDynamic, adLockOptimistic
==========================================
Code is snippet from an excel vba macro.
However, on just 1 laptop, we get following error message:
Error # -2147221164 was generated by Provider Class not registered
Error occurs on this line below:
adoRS1.Open strSQL1, adoCN, adOpenDynamic, adLockOptimistic
We've verified mdac is at 2.8 and all xp and office 2002 service packs
applied.
Not sure how to debug or figure out. Using oledb, so odbc trace didnt work.
Any ideas?
TIA.
======================================
Set adoCN = New ADODB.Connection
' ADO Connections for SQL Server
With adoCN
.Open "Provider=SQLOLEDB;" & _
"Data Source=xxx.xx.x.xx;" & _ ' IP address has
been changed from working IP.....
"Initial Catalog=dbFP_Summary;" & _
"User Id=fpsummaryrw;" & _
"Password=fpsummaryrw"
On Error GoTo ErrorHandler
End With
strSQL1 = "Select * From tbl_ESM_estimates Where " & _
"CR_Number = '" & strCRNum & "' And " & _
"System_ID = '" & strSystemID & "' And " & _
"TNC_Level = '" & strTNCLevel & "' "
strAudit = "tbl_ESM_estimates_Audit"
Set adoRS1 = New ADODB.Recordset
Set adoRS2 = New ADODB.Recordset
adoRS1.Open strSQL1, adoCN, adOpenDynamic, adLockOptimistic
adoRS2.Open strAudit, adoCN, adOpenDynamic, adLockOptimistic
==========================================