Hi, I hope this is an easy question for you guys...
I have an application that I need to be able to switch from sqlserver
to access at runtime.
I can change from one sqlserver installation to another using this
code...
Dim nS = "Data Source=" & Server & ";Initial Catalog=" & DatabaseName &
";Persist Security Info=True;User ID=" & UserName & ";Password= " &
Password
CompanyTableAda pter.Connection .ConnectionStri ng = nS
I was hoping to be able to change to an access database using the
following:
Dim nS = "Provider=Micro soft.Jet.OLEDB. 4.0;Data Source=" & dbname
CompanyTableAda pter.Connection .ConnectionStri ng = nS
but whatever access string I try I get errors, such as "keyword
'Provider' not recognised"
can anyone point me in the right direction please?
thanks
Tim
I have an application that I need to be able to switch from sqlserver
to access at runtime.
I can change from one sqlserver installation to another using this
code...
Dim nS = "Data Source=" & Server & ";Initial Catalog=" & DatabaseName &
";Persist Security Info=True;User ID=" & UserName & ";Password= " &
Password
CompanyTableAda pter.Connection .ConnectionStri ng = nS
I was hoping to be able to change to an access database using the
following:
Dim nS = "Provider=Micro soft.Jet.OLEDB. 4.0;Data Source=" & dbname
CompanyTableAda pter.Connection .ConnectionStri ng = nS
but whatever access string I try I get errors, such as "keyword
'Provider' not recognised"
can anyone point me in the right direction please?
thanks
Tim
Comment