0
我想保留web.config
文件的某些部分不在web.config文件中。所以我使用configSource
属性并引用其他一些文件。当我在web.config
以外的文件中添加多个配置时,VS 2010将显示红色波浪线。我们是否需要为使用configSource属性的web.config文件的每个部分分别配置文件?
是否需要为使用configSource
属性的web.config文件的每个配置节单独配置.config
文件?如果没有,如何摆脱VS2010的投诉?
相关章节如下:
<MyApplication.Configuration file="Configuration\customAppConfiguration.config" />
<system.diagnostics configSource="Configuration\customAppConfiguration.config" />
的customAppConfiguration.config
文件看起来是这样的:
<?xml version="1.0"?>
<MyApplication.Configuration>
<!-- Contains My Application's configuration -->
</MyApplication.Configuration>
<system.diagnostics>
<!-- Diadnostic's configuration -->
</system.diagnostics>