我在部署 Web 应用程序时遇到错误。
错误标题是 Could not open Source file: Could not find a part of the path
'Could not open Source file: Could not find a part of the path 'E:\ARCHIVES\Projects\Main\Jahan.Handicraft\Jahan.Handicraft.Web.Mvc.UmbracoCms.App\obj\Release\AspnetCompileMerge\TempBuildDir\App_Plugins\UmbracoForms\Data\Web.config;\App_Plugins\UmbracoForms\Data\Web.config'.'.
我用过
Umbraco 7.4.3
和 ASP.NET MVC
在我的项目中。我想在本地主机上部署它。
我怎么解决这个问题?
最佳答案
这是在子级配置文件中转换连接字符串的失败尝试。
要禁用此转换,请编辑 Properties\PublishProfiles
下的发布配置文件并设置 AutoParameterizationWebConfigConnectionStrings
的值元素到 false
.如果缺少则添加元素。
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<!--
...
Other settings
...
-->
<AutoParameterizationWebConfigConnectionStrings>false</AutoParameterizationWebConfigConnectionStrings>
</PropertyGroup>
</Project>
我从这个博客(不是我的)得到的:http://blog.aabech.no/archive/web-deploy-says-could-not-open-source-file-some-webconfig-when-you-publish-an-umbraco-site/
关于asp.net-mvc - 部署 Web 应用程序时出错 "Could not open Source file: Could not find a part of the path",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/40824734/