views:

610

answers:

1

I've been trying to run the Silverlight Business Application template but it fails when I try to register. I have SQL Express with an MSSQLSERVER instance and I've defined the standard aspnetdb created.

The error is:

Submit operation failed.  Unable to connect to SQL server database.

 at System.Web.DomainServices.ReflectionDomainServiceDescriptionProvider.ReflectionDomainOperationEntry.Invoke(DomainService domainService, Object[] parameters)
   at System.Web.DomainServices.DomainService.InvokeDomainOperationEntry(DomainOperationEntry domainOperationEntry, Object[] parameters, ChangeSetEntry operation)
   at System.Web.DomainServices.DomainService.InvokeCudOperations(ChangeSet changeSet)
   at System.Web.DomainServices.DomainService.ExecuteChangeSet(ChangeSet changeSet)
   at System.Web.DomainServices.DomainService.Submit(ChangeSet changeSet)
   at System.Web.Ria.Services.ChangeSetProcessor.Process(DomainService domainService, IEnumerable`1 changeSetEntries)
   at System.Web.Ria.Services.SubmitOperationBehavior.SubmitOperationInvoker.InvokeCore(Object instance, Object[] inputs, Object[]& outputs)
+2  A: 

You need the aspnetdb database created by running aspnet_regsql.exe against a SQL Server instance called SQLExpress - this can be found in the LocalSqlServer connection string in machine.config. Or by replacing the LocalSqlServer connection string with something that points to your SQL instance. Something like this:

<remove name="LocalSqlServer"/>
<add name="LocalSqlServer" 
     connectionString="Data Source=YOURCOMPUTER;Initial Catalog=aspnetdb;Integrated Security=True" 
     providerName="System.Data.SqlClient"/>
serialhobbyist