Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Can't connect to SQL 2008R2
Message
From
21/06/2010 14:29:18
James Blackburn
Qualty Design Systems, Inc.
Kuna, Idaho, United States
 
 
To
All
General information
Forum:
ASP.NET
Category:
Databases
Title:
Can't connect to SQL 2008R2
Environment versions
Environment:
C# 4.0
OS:
Windows 7
Miscellaneous
Thread ID:
01469983
Message ID:
01469983
Views:
86
Hi All

I have just installed the developer version of msSql2008R2. I can't seem to get VS2010 to connect using asp.net. I can add a connection using the server explorer. It seems that the problem is with the web.config connection string but I can't seem to get it working. This is what worked using sqlexpress.
    <add name="LocalSqlServer" connectionString="data source=.\SQLEXPRESS;Integrated Security=SSPI;AttachDBFilename=|DataDirectory|aspnetdb.mdf;User Instance=true" 
         providerName="System.Data.SqlClient" />
  </connectionStrings>
This is the closest I have come to making it work with sqlserver except it won't recognize the trusted user.
    <add name="ApplicationServices"
         connectionString="data source=JIM3\MSSQL2008R2;Database=aspnetdb.mdf; Trusted_Connection=True"
        providerName="System.Data.SqlClient" />
Thanks.
Next
Reply
Map
View

Click here to load this message in the networking platform