Antarctica
Posts: 110
Joined: Tue Jul 08, 2014 9:24 am

Remove multi-comments from XML file

Wed Aug 20, 2014 5:37 pm

I have an XML file in our installer. On every patch, this file is edited, not removed.
In this file, I have a comment. Every time a patch was applied, the comment was duplicated.
I now removed the comment from the XML file.
Still, a dozen or so comments remain in the XML file of our early adopters.

Can I remove these comments somehow?

Daniel
Posts: 8237
Joined: Mon Apr 02, 2012 1:11 pm
Contact:  Website

Re: Remove multi-comments from XML file

Thu Aug 21, 2014 2:37 pm

Hello,

I'm afraid this behavior is caused by an Advanced Installer limitation. Our XML update support will insert a comment contained by an XML file (added in XML format) every time the XML file is updated at install time. This is because our XML update support cannot locate an existing comment in the XML file on disk, so it will insert it in the XML file from disk every time when updating the XML.

However, as a workaround, in order to avoid this issue you can remove the comments within the XML file contained by your upgraded version of your installation project. Just open the .aip (project file) of your upgraded product version, go to "Files and Folders" page, double click on your XML file, and in the "Edit XML File" dialog delete all of your XML comments. Then, rebuild your projects and test again the scenario.

Let us know if this helped.

All the best,
Daniel
Daniel Radu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Antarctica
Posts: 110
Joined: Tue Jul 08, 2014 9:24 am

Re: Remove multi-comments from XML file

Thu Aug 28, 2014 3:19 pm

I already did what you mentioned:
I now removed the comment from the XML file.
But as you said, I can't strip already-deployed comments from the file during update using AI.

If I should ever have some spare time, I will write a short Custom Action for this and post it here.

Dan
Posts: 4513
Joined: Wed Apr 24, 2013 3:51 pm

Re: Remove multi-comments from XML file

Tue Sep 19, 2017 3:27 pm

Hello,

This was fixed in version 14.3 of Advanced Installer released on September 18th, 2017.

Best regards,
Dan
Dan Ghiorghita - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Collins
Posts: 138
Joined: Wed Oct 12, 2016 2:57 pm

Re: Remove multi-comments from XML file

Tue Nov 14, 2017 4:10 pm

Hi Dan,

What was fixed? The installer to not duplicate comments sections up upgrades?

I am still seeing the same behavior with 14.4.1. I have a comment section that is important and would rather not remove it from the Windows Installer xml.

Daniel
Posts: 8237
Joined: Mon Apr 02, 2012 1:11 pm
Contact:  Website

Re: Remove multi-comments from XML file

Wed Nov 15, 2017 4:15 pm

Hello Collins,

Could you please send us the .aip (project file) to support at advancedinstaller dot com so we can investigate its settings? When using the AI 14.4.1 version you should not end up anymore with duplicated XML comments.

All the best,
Daniel
Daniel Radu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Collins
Posts: 138
Joined: Wed Oct 12, 2016 2:57 pm

Re: Remove multi-comments from XML file

Wed Nov 15, 2017 5:07 pm

Thanks Dan. I just emailed you the file and all the information.

Daniel
Posts: 8237
Joined: Mon Apr 02, 2012 1:11 pm
Contact:  Website

Re: Remove multi-comments from XML file

Fri Nov 17, 2017 10:30 am

Hello Collins,

Thank you for your sent file. Indeed using your project file configuration we replicated the duplicate XML comments behavior after an upgrade installation on our end too. We will try to fix this issue and let you know as soon as a fix will be available.

All the best,
Daniel
Daniel Radu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Dan
Posts: 4513
Joined: Wed Apr 24, 2013 3:51 pm

Re: Remove multi-comments from XML file

Wed Feb 21, 2018 1:41 pm

Hello,

This was fixed in version 14.6 of Advanced Installer released on February 19th, 2018.

Best regards,
Dan
Dan Ghiorghita - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Building Installers”