Unable to connect to datasource through Web Site Administration tool

Oct 22, 2012 at 8:51 PM

Hi I have been following the tutorial up to page 83 of the pdf document but when i try to create an admin user with the ASP.NET website administration tool. I get the follwoing response on clicking the security tab.

There is a problem with your selected data store. This can be caused by an invalid server name or credentials, or by insufficient permission. It can also be caused by the role manager feature not being enabled. Click the button below to be redirected to a page where you can choose a new data store.

The following message may help in diagnosing the problem: Unable to connect to SQL Server database.

I am using sqlcompact 4.0 as datastore.

Oct 23, 2012 at 2:51 PM

I'm having the same problem this morning.  No luck.  After much playing around, here are my connection strings.

 

  <connectionStrings>          
    <add name="MusicStoreEntities" connectionString="Data Source=|DataDirectory|mvc3Movie.sdf" providerName="System.Data.SqlServerCe.4.0"/> 
    <add name="DefaultConnection" connectionString="Data Source=|DataDirectory|mvc3Movie.sdf" providerName="System.Data.SqlServerCe.4.0"/>
    <!--MusicStoreEntities-->
    <!--"System.Data.SqlServerCe.4.0"-->   
    <!--<add name="DefaultConnection" providerName="System.Data.SqlClient" connectionString="Data Source=(LocalDb)\v11.0;Initial Catalog=aspnet-mvc3Movie-20121011132423;Integrated Security=SSPI;AttachDBFilename=|DataDirectory|\aspnet-mvc3Movie-20121011132423.mdf" />-->
  </connectionStrings>

Nov 26, 2012 at 6:07 PM

I just did what you suggest (add a DefaultConnection connectionString), did not change anything. I am a bit stuck if I can't make this to work. Too bad as it has been progressing nicely so far, with a few hicups easily solved with the help of my friend Google....