I want to setup login roles for my application.
When I go to the ASP.NET Configuration Tool and Click on the Provider Tab,
I select: Select a single provider for all site management data
I get this: AspNetSqlProvider
When I click on the test hyperlink, I get this message:
Could not establish a connection to the database.
If you have not yet created the SQL Server database, exit the Web Site Administration tool, use the aspnet_regsql command-line utility to create and configure the database, and then return to this tool to set the provider.
1) I created a ASPNETDB.MDF file in the APP_Data Folder
2) Ran the aspnet_regsql.exe tool that created the database ASPNETDB in my SQL Server
3) Edited the maching.config file for
<connectionStrings>
<add name="LocalSqlServer" connectionString="data source=.\SQLEXPRESS;Integrated Security=SSPI;AttachDBFilename=|DIRECTORY|\App_Data\aspnetdb.mdf;User Instance=true" providerName="System.Data.SqlClient"/>
</connectionStrings>
In DIRECTORY, I replaced DIRECTORY with the actual path: C:\Documents and Settings\Owner\My Documents\Visual Studio 2010\WebSites\myProject
Don’t know what else I am missing to get the ASP.NET Configuration Tool to work
Thanks in advance for any help!
Solved the issue :
1) Created a new website and copied the database it created in the
app_datafolder tomyprojectfolder.app_data
2) Copied the differences in the
webconfigsections from the website to myproject.Configuration tool now works correctly.