M
Martin Tallett
I need to run an Access job overnight which has linked tables via ODBC to an
IBM iSeries DB2 database. The problem arises when the first connection is
made to the iSeries as a popup appears requesting a username and password -
not a good idea in the middle of the night! Therefore I want to supply the
username and password somehow without having to be there in person... I have
tried the following code to refresh the ODBC linked tables and supply the
username and password in the connect string but I get the error message -
"Run-time error 3000: Reserved error (-7778); there is no message for this
error."
Any ideas please?
Public Function ConnectMe() As String
Dim db As DAO.Database
Dim sConnect As String
Set db = CurrentDb
sConnect = "ODBC;Driver={Client Access ODBC Driver
(32-bit)};System=S44436A;Uid=TALLETTM;PWD=MyPassword"
db.TableDefs(6).Connect = sConnect
db.TableDefs(6).RefreshLink
End Function
IBM iSeries DB2 database. The problem arises when the first connection is
made to the iSeries as a popup appears requesting a username and password -
not a good idea in the middle of the night! Therefore I want to supply the
username and password somehow without having to be there in person... I have
tried the following code to refresh the ODBC linked tables and supply the
username and password in the connect string but I get the error message -
"Run-time error 3000: Reserved error (-7778); there is no message for this
error."
Any ideas please?
Public Function ConnectMe() As String
Dim db As DAO.Database
Dim sConnect As String
Set db = CurrentDb
sConnect = "ODBC;Driver={Client Access ODBC Driver
(32-bit)};System=S44436A;Uid=TALLETTM;PWD=MyPassword"
db.TableDefs(6).Connect = sConnect
db.TableDefs(6).RefreshLink
End Function