how to avoid login prompt for Linked Tables thru DSN entry?



I am currently working on task of linking tables in MDB to tables in SQL
Server 2005 so that data storage can be shifted SQL Server.

I have created a DSN entry and using that DSN I have linked all required
tables from the SQL Server.I have choosen SQL Server security and provided
username and password during the creation of the DSN. At the end of the
creation process , I also tested the connection and found to be successful.

However, when invoking the application, Access prompts me for user name and
password. I also noticed that secured connection is selected in the prompt
though I explicitly selected "SQL server Authentication" while creating the

Is there any way to avoid this dialogue apearing every time?

Thanks in advance!


Mary Chipman [MSFT]

One way to do this is to supply the ODBC connection string in code
instead of using a DSN. You can prompt the user for the name and
password and create the linked TableDef object. This avoids the
necessity of storing the name and password in a DSN, which is not


Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question