SQL Server Connection String - Access adp project (1 Viewer)

ak_ls

Registered User.
Local time
Today, 00:41
Joined
Oct 18, 2008
Messages
44
The following VBA code that connects to SQL Server in an Access adp project works without any problem on my computer but does not work on another user's computer.

CurrentProject.CloseConnection

ConStr = "Provider=sqloledb;Data Source=UK009125D\SQLExpress;Integrated Security=SSPI;Initial Catalog=MyDatabase;User ID=xxxxxxxx;Password=yyyyyyyy"

CurrentProject.OpenConnection ConStr


Is there some mistake in the above VBA Code? Please help.

With Thanks
Ashok
 

ak_ls

Registered User.
Local time
Today, 00:41
Joined
Oct 18, 2008
Messages
44
Thanks SQL Hell.

As pointed out by you, I have removed "Integrated Security=SSPI" from the connection string and it is now working. The database authentication is through SQL server and not through Windows.

Ashok
 

Users who are viewing this thread

Top Bottom