Positive Parrot
New Member
- Joined
- Jan 16, 2004
- Messages
- 35
All,
We have just moved the following Excel VBA code from NT4 (Excel 97) where it worked fine to XP (Excel 2003) where I am getting the error message at the Set conOra line
Run time error 3146: ODBC call failed
The Oracle ODBC on the new XP machine seems to have been set up OK and I can log onto Oracle from outside Excel successfully.
Has anybody any ideas how I can narrow the problem down?
Many Thanks,
PP
We have just moved the following Excel VBA code from NT4 (Excel 97) where it worked fine to XP (Excel 2003) where I am getting the error message at the Set conOra line
Run time error 3146: ODBC call failed
The Oracle ODBC on the new XP machine seems to have been set up OK and I can log onto Oracle from outside Excel successfully.
Has anybody any ideas how I can narrow the problem down?
Code:
Dim wrkOra As Workspace
Dim conOra As Connection
Set wrkOra = CreateWorkspace("Oracle Workspace", "", "", dbUseODBC)
Application.StatusBar = "Retrieving Site data from Oracle..."
Set ws = ActiveWorkbook.Worksheets("Site Data")
Set conOra = wrkOra.OpenConnection( _
Name:="Oracle Connection", _
Options:=dbDriverComplete, _
ReadOnly:=True, _
Connect:="ODBC;DSN=PRODCORP;DATABASE=Oracle73;UID=dluser;PWD=datalens")
Many Thanks,
PP