I have a SQL Server database already used for login credentials (among others) that all of the correct tables are I'm trying to connect to I have this code in my web.config file: And when I open the Website Administration tool & gt; Security, I get the following error: There is a problem with your selected data store This may be due to an invalid server name or credentials or insufficient permissions. This role can also be due to the managerial facility not being enabled. Click the button below to redirect to that page where you can choose a new data store. The following messages can help diagnose the problem: Adding unfamiliar configuration sections (C: \ Documents and Settings \ Tunnel \ My Documents \ Visual Studio 2010 \ Web Sites \ zsrblank \ web.config line 7 ) I am trying to fix it for 5 hours when I have website administration tools & gt; Provider and test it always say:. Successfully relation to the database Please help I followed this tutorial in fact and get the same error: I think there is a slight typo here. In the tag, the property connectionstring should actually be connectionstring . Try it If the server and database names are correct and the user credentials are correct, then it should now work. Also make sure that your subscription and role providers in your web configuration are now using your new connection string. Something like this should be seen. Also check that the role manager has been enabled. Hope this helps Good luck ...
& lt; Connection Keystroke & gt; & Lt; Add name = "abcdCS" provider name = "System.Data.SqlClient" connectionString = "data source = SERVERNAME; initial catalog = SCRUMAPIUI; integrated security = false; user id = MYUSERNAME; password = MYPASSWORD; MultipleActiveResultSets = True" /> ; & Lt; / ConnectionStrings & gt;
& lt; Membership & gt; & Lt; Providers & gt; & Lt; Clear /> & Lt; Add name = "aspNetSqlMembershipProvider" type = "System.Web.Security.SqlMembershipProvider" enable connectionStringName = "abcdCS", password retrieval = "false" enable passwordResetset = "true" requires question and answer = "wrong" UniqueEmail = " False "maxInvalidPasswordAttempts =" 5 "minRequiredPasswordLength =" 6 "Minimum Required Nonfanumeric Alphabets =" 0 "PasswordAvsvindo =" 10 "Application Name =" / "/> & Lt; / Providers & gt; & Lt; / Subscription & gt;
& lt; RoleManager enabled = "true" & gt;
Sunday, 15 August 2010
c# - Can't correctly connect to SQL Server in ASP.NET application -
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment