I have the following connection string in a Excel VBA project:
oCon.ConnectionString = "Driver={SQL Native Client};Server=SQL;Database=D1; Trusted_Connection=yes;"
On my laptop this works perfectly. But when I try it out on another computer I get an error:
I get this error when oCon.Open on debugging:
Run-time error '-2147467259(80004005)':
Automation error
Unspecified error
On first time run i get the error:
Run-time error '-2147467259(80004005)':
[Microsoft][ODBC Driver Manager] Data source name not found and no
default driver specified
What is wrong?
(Posted it here since it is vb code)