In some MS Access 97 applications I developped in the past I was using a VBA code to create a ODBC linked table.
Here is the MS Access97 code.
Dim tdfLinked As TableDef
Dim ConnectString as String
ConnectString = "ODBC;DSN=B5P2;DBALIAS=B5P2;UID=MyLogon;PWD=MyPswd;TABLE=AB5BL001.MPR2"
Set tdfLinked = CurrentDb.CreateTableDef("MPRdb"
tdfLinked.Connect = ConnectString
tdfLinked.SourceTableName = "AB5BL001.MPR2"
tdfLinked.Attributes = dbAttachSavePWD
CurrentDb.TableDefs.Append tdfLinked
We are now migrating to MS Access2000. So, the code here above is not more working.
Is somebody can help me converting that code in MS Access2000?
Thanks
Here is the MS Access97 code.
Dim tdfLinked As TableDef
Dim ConnectString as String
ConnectString = "ODBC;DSN=B5P2;DBALIAS=B5P2;UID=MyLogon;PWD=MyPswd;TABLE=AB5BL001.MPR2"
Set tdfLinked = CurrentDb.CreateTableDef("MPRdb"
tdfLinked.Connect = ConnectString
tdfLinked.SourceTableName = "AB5BL001.MPR2"
tdfLinked.Attributes = dbAttachSavePWD
CurrentDb.TableDefs.Append tdfLinked
We are now migrating to MS Access2000. So, the code here above is not more working.
Is somebody can help me converting that code in MS Access2000?
Thanks