【发布时间】:2010-11-10 11:38:37
【问题描述】:
我正在研究 web.config 转换文件概念。我有三个网络配置。一种是暂存、生产、部署。我对这三个有不同的连接信息。
Web.Config:
<connectionStrings>
<add name="MyGallery"
connectionString="Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=DevelopmentStorageDb;Data Source=BALA\SQLEXPRESS" />
</connectionStrings>
Web.Config.Production:
<add
name="MyGallery"
connectionString="Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=SharePoint_Config;Data Source=BALA\SQLEXPRESS"
xdt:Transform="Replace" xdt:Locator="Match(name)"
/>
现在我构建了运行良好的代码。我已经创建了包。当我在生产模式下运行代码时,新的连接字符串没有占用。
我该如何解决这个问题。我需要额外的努力才能将它移到某个地方
【问题讨论】:
标签: visual-studio visual-studio-2010 msdeploy web-config-transform