Asp.net mvc 如何让我的Windows Azure Worker角色连接到基于Ado.NEt实体的数据库
我在ASP.NET MVC2中构建了一个后端,它有一个底层的基于ADO.NET实体的数据库 在MVC后端,我调用我的数据库实体,即:Asp.net mvc 如何让我的Windows Azure Worker角色连接到基于Ado.NEt实体的数据库,asp.net-mvc,ado.net,azure,azure-worker-roles,Asp.net Mvc,Ado.net,Azure,Azure Worker Roles,我在ASP.NET MVC2中构建了一个后端,它有一个底层的基于ADO.NET实体的数据库 在MVC后端,我调用我的数据库实体,即: Entities entities = new Entities(); …这一切都很好 不幸的是,在我的Azure/mvc2项目中,我的工作者角色使Azure项目抛出奇怪的异常: "The specified named connection is either not found in the configuration, not intended to be
Entities entities = new Entities();
…这一切都很好
不幸的是,在我的Azure/mvc2项目中,我的工作者角色使Azure项目抛出奇怪的异常:
"The specified named connection is either not found in the configuration, not intended to be used with the EntityClient provider, or not valid."
女士们先生们,有什么想法吗?我自己解决了——这是一个PEBKAC问题。 必须在工作者角色的App.config(从ASP/NET MVC2项目的Web.config复制粘贴)中手动设置配置字符串 现在一切正常