Last post Jul 06, 2017 07:45 PM by noJedi
Jun 09, 2017 09:37 AM|David1656145|LINK
I was redirected here from
In web.config I have:
<setting name="ProfitConnectorToken" serializeAs="String" xdt:Transform="Replace" xdt:Locator="Match(name)">
In my parameters.xml:
<parameter name="ProfitConnectorToken" description="Description for ProfitConnectorToken" defaultvalue="__PROFITCONNECTORTOKEN__" tags="">
<parameterentry kind="XmlFile" scope="\\web.config$" match="/configuration/applicationSettings/App.Properties.Settings/setting[@name='ProfitConnectorToken']/value/text()" />
And in my SetParameters.xml:
<setParameter name="ProfitConnectorToken" value="<token><version>1</version><data>XXXXXXXXXXXXXXXXXXXXXXXXX</data></token>" />
But this value is not set when the web application is deployed. When I change my SetParameters.xml to:
<setParameter name="ProfitConnectorToken" value="TEST" />
It does work, so my XPath is correct. Why is the encoded xml value not set?
Jun 12, 2017 05:47 AM|EvenMa|LINK
According to your description, that seems like couldn’t upload the changed files.
For MSDeploy, the minimal unit is file, not file content, MSDeploy is not notice the contents of the document, only notice the file itself whether has been modified.
So in your case, I suggest you could try it again to confirm this issue, when using MSDeploy, you could preview the changes of this time in the feature of preview.’
For more details about using MSDeploy, you could refer to the following link.
https://msdn.microsoft.com/en-us/library/dd465337(v=vs.110).aspx#Previewing Changes and Publishing the Project
If you have any other questions, please feel free to contact me any time.
Jun 12, 2017 08:29 AM|David1656145|LINK
It is working because when I put in the value "TEST" it works and I see this value in the deployed web application. When I put in the encoded xml string it doesn't work, the value in the deployed web application remains the default value.
Jun 13, 2017 07:54 AM|EvenMa|LINK
After I searched about this issue on internet, that’s might a BUG.
See the following link, that’s similar as yours, and a microsoft employee said will fix that in an upcoming release.
Jul 06, 2017 07:45 PM|noJedi|LINK
have you tried putting the XML in a separate file?
encoded xml in webconfig is always painful and there are pros/cons to this approach, but might be worth a shot...?