0

I want to add a connection string and give it name..

The connection string belongs to aspnetdb.mdf which was created when i added my CreateUserWizard.

This is its connection string:

Data Source=.\SQLEXPRESS;AttachDbFilename="D:\Documents and Settings\Dima\My Documents\Visual Studio 2010\WebSites\WebSite10\App_Data\ASPNETDB.MDF";Integrated Security=True;User Instance=True

Now when i add it to the config file:

    <connectionStrings>
        <add name="YourGuruDB" connectionString="Data Source=.\SQLEXPRESS;AttachDbFilename="D:\Documents and Settings\Dima\My Documents\Visual Studio 2010\WebSites\WebSite10\App_Data\ASPNETDB.MDF";Integrated Security=True;User Instance=True" providerName="System.Data.SqlClient"/>
  </connectionStrings>  

it shows me weird line underneath of part of the string which prevents it from being executed..

I also dont understand the connection between the membership config and the database

    <membership defaultProvider="MyMembershipProvider">  

What is this provider? Shouldnt it be .NET Framework provider? Same as the aspnetDB

Also why do i see red Xes on the databases i created/and the system created whenever i open my server explorer?

1 Answer 1

1

try taking out the double quotes within the connectionString="" attribute.

Sign up to request clarification or add additional context in comments.

2 Comments

Use single quotes instead, if your sub-string contains spaces.
what about the red X that appears on my database that is in my Server explorer

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.