每次我创建新项目(仅在我之前在校园计算机上创建的项目没有发生的新项目上)然后添加表格和屏幕然后我调试我在桌面应用程序上显示红色 x 标记和“无法加载数据。请检查你的网络连接”和视觉工作室:
An exception of type 'System.Data.EntityException' occurred in System.Data.Entity.dll but was not handled in user code
Additional information: The underlying provider failed on ConnectionString.
on Application1\Application1\Application1.Server\GeneratedArtifacts\ApplicationDataObjectContext.cs
public ApplicationData(string connectionString) : base(connectionString, "ApplicationData")
{
OnContextCreated();
}
inside connectionString
是
"metadata=res://Application.Server/ApplicationData.csdl|res://Application.Server/ApplicationData.ssdl|res://Application.Server/ApplicationData.msl;provider=System.Data.SqlClient;provider
connection string=\"Data
Source=(LocalDB)\\v11.0;AttachDbFilename='E:..Desktop\\Application1\\Application1\\Bin\\Data\\ApplicationDatabase.mdf';Integrated
Security=True;Connect Timeout=30;MultipleActiveResultSets=True\""
我正在运行 Visual Studio 更新 1,然后我卸载更新 1。我尝试卸载 Visual Studio 并再次安装,但没有结果。我在 win7 pro sp 1 (x64)
更新 :
我尝试重新安装windows(仍然使用win7pro sp1)并安装vs2013,但仍然得到同样的错误。