I have a database and I have to have it connect to an external data source through an ODBC connection. I decided to utilize the function transferdatabase like
DoCmd.TransferDatabase acLink, "ODBC Database", "ODBC;DSN=" & datasource1 & ";UID=" & Uname1 & ";PWD=" & pass1 & ";DATABASE=stamprod_sql", acTable, "exch_tools_trade", "dbo_exch_tools_trade"
datasource1, uname1 and pass1 are variables that hold the values entered from text boxes. I noticed that if I leave off the user name and password and just have the datasource name, it works fine. Why is this? Am I doing something wrong?
Thank you
DoCmd.TransferDatabase acLink, "ODBC Database", "ODBC;DSN=" & datasource1 & ";UID=" & Uname1 & ";PWD=" & pass1 & ";DATABASE=stamprod_sql", acTable, "exch_tools_trade", "dbo_exch_tools_trade"
datasource1, uname1 and pass1 are variables that hold the values entered from text boxes. I noticed that if I leave off the user name and password and just have the datasource name, it works fine. Why is this? Am I doing something wrong?
Thank you