Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

trusted SQL Server connection

When I attempt to make a connection from my console app to my sqlExpress. I get the following error:

The user is not associated with a trusted SQL Server connection.

I have:

      Switched users
      Switched passwords
      Switched Servers
      Switched Databases

I always get the same error. I am using VS 2010 and Sql Server 2005

Here is my current connection string

SqlDatabase sqlDatabase = new SqlDatabase(@"Server=localmachineName\SQLEXPRESS;   database=database1;user id=username; password=mypassword;");
like image 936
dan_vitch Avatar asked Jun 13 '26 17:06

dan_vitch


1 Answers

Is sql authorization enabled?

Check this if you haven't already: http://www.hosting.com/support/vps/windows/mixedmode/

like image 147
MatthewMartin Avatar answered Jun 16 '26 06:06

MatthewMartin



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!