Let's suppose I have a configuration section on an external file, with the following element:

<my-config>
    <!-- ... -->
    <file value="XXX" />
    <!-- ... -->
</my-config>

Now, I want value to be YYY when the solution is built in Release.

Im using Web Deploy for the web application deployment so I have the full benefits of Web.config Transformations

I know how to achieve this if the configuration section is embedded in the Web.config:

<my-config>
   <file value="YYY" xdt:Transform="SetAttributes(value)" />
</my-config>

But how can I accomplish the same thing when the section is on an external file?

Related posts

Recent Viewed