Connection to Access database on Web Server from VB Winforms application

  • Thread starter Thread starter Johnny Jörgensen
  • Start date Start date
J

Johnny Jörgensen

Does anybody know if it's possible to do a Windows application that can read
and write to an Access databas located on a web server that only accepts DNS
connections.

Has anybody got a code example for that and/or tips?

TIA,
Johnny J.
 
Does anybody know if it's possible to do a Windows application that can read
and write to an Access databas located on a web server that only accepts DNS
connections.

Has anybody got a code example for that and/or tips?

TIA,
Johnny J.


if you want to use a DSN in your connection string (User DSN or System
DSN) you need to use the ODBC.NET Data Provider. To accomplish this,
just build the System
DSN using the ODBC Data Source Admin tool. In the tool you have to
browse to the mdb file location. Then in your code just use:

Dim cnOdbc as OdbcConnection = New OdbcConnection("DSN=myAccessDSN")

remote connection:

Private ConnString As String =
"Server=10.144.162.111;Database=DNS;Trusted_Connection=True"
 
Back
Top