c# - System.Data.SqlClient.SqlException' occurred in EntityFramework.dll but was not handled in user code -


i worked c#(started work). @ first created model. , model created mvc 5 controller views, using entity framework. thought correct (that necessary table created model, , can worked local database), when run application , go page http://localhost:49640/controllername error:

additional information: network-related or instance-specific error occurred while establishing connection sql server. server not found or not accessible. verify instance name correct , sql server configured allow remote connections. (provider: sql network interfaces, error: 52 - unable locate local database runtime installation. verify sql server express installed , local database runtime feature enabled.)

i tried find solution, didn't. understood can problems connectionstrings in web.config or problems connection server, how solve problem?

my connection strings:

<connectionstrings> <add name="defaultconnection" connectionstring="data source=(localdb)\v11.0;attachdbfilename=|datadirectory|\aspnet-musicapplication-20150620120938.mdf;initial catalog=aspnet-musicapplication-20150620120938;integrated security=true"   providername="system.data.sqlclient" /> 

i download sqllocaldb , installed it, solve problem. link connection local db failed 52 helped me.


Comments

Popular posts from this blog

twig - Using Twigbridge in a Laravel 5.1 Package -

jdbc - Not able to establish database connection in eclipse -

firemonkey - How do I make a beep sound in Android using Delphi and the API? -