Dean.Wilson
Posts: 6
Joined: Mon Aug 22, 2011 10:17 am

Merge XML file with user selected XML file

Hi there,

I can overwrite parts of the Web.config with values provided in the UI by adding a Windows-Installer XML file containing the nodes to overwrite, no problem.
I can also overwrite entire XML files with a user selected XML file by using the Move / Copy custom action.

But now I need to overwrite parts of the Web.config with a user selected XML file that will contain just the nodes that need overwriting. So some nodes in the Web.config will be overwritten by values provided in the UI (already working, no problem) and other sections of the web.config will be overwritten by a user selected XML file.

How can this be done?

Thanks
mihai.petcu
Posts: 3860
Joined: Thu Aug 05, 2010 8:01 am

Re: Merge XML file with user selected XML file

Hello,

Unfortunately, there is no predefined support for this functionality in Advanced Installer.

To select entire .XML files at install time that will overwrite other installed .XML files( web.config ), you would have to implement your own custom action.

This custom action should parse the selected .XML file and set some public properties referenced in the XML editor for your web.config file.

All the best,
Mihai
Mihai Petcu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”