StringCollection app.config

I have an app settings that is a type of Specialized.StringCollection, its stored in the app.config as:

<setting name="settingName" serializeAs="Xml">
		<ArrayOfString xmlns:xsi=""

Is there anyway of changing the value of string1\string2 during a deployment? I’ve tried putting the ArrayOfString node into a variable but it XML encodes it when updating the app.config.

Hi Badger,

Thanks for getting in touch! You would have to use the ‘substitute variables in files’ feature to make those substitutions. Creating a variable for both string1 and string2 then defining them in the config as #{String1} and #{String2}. You will have to name the config file in the list of files to check.

Hope that helps!

Hi, I am trying to do this with my web.config, after the tranformations have taken place. But the variables are not replaced and remain unchanged in the actual web.config that is deployed.

I have the file listed in the files and the checkbox is checked.

What am I doing wrong?

<globalization requestEncoding="UTF-8" responseEncoding="UTF-8" uiCulture="#{uiculture}" culture="#{culture}" xdt:Transform="Replace" />

Hi Jim,

You need to turn on the ‘Substitute variables in files’ feature and define the config file explicitly. Please see my screenshots. Also do not forget to create a new release after making these changes.