We’re moving our forums to a new platform.

You can still browse and search existing topics, but you can no longer create new topics or post replies.

For questions, technical issues, or feature requests, please don’t hesitate to contact our support team at support@advancedinstaller.com.

Thank you for your understanding!

zeiddev
Posts: 103
Joined: Sat Aug 10, 2013 12:30 am

Appending to XML file

I have the following XML which I have abbreviated for simplicity:

<CustomDataSourceDS>
<CustomDataSource>
<FriendlyName>XX</FriendlyName>
<Creator>DZ</Creator>
</CustomDataSource>
<CustomDataSource>
<FriendlyName>YY</FriendlyName>
<Creator>DZ</Creator>
</CustomDataSource>

It is possible that there will be other CustomDataSource entries from other creators. I would like to add mine if the friendly name entry does not already exist. However I am not sure how to get the conditions to look forward. I am using the XML editor to add these nodes as shown:

Annotation 2019-05-29 101446.jpg
Annotation 2019-05-29 101446.jpg (55.84 KiB) Viewed 3740 times
zeiddev
Posts: 103
Joined: Sat Aug 10, 2013 12:30 am

Re: Appending to XML file

Any thoughts about this???
Catalin
Posts: 7853
Joined: Wed Jun 13, 2018 7:49 am

Re: Appending to XML file

Hello,

In order to achieve this, I think that you can create an XML search (which will perform a search for your entry) and then use the result of your search as a condition. For more information, also please have a look on our "XML Search Properties" article which I think you may find useful.

Hope this helps.

Best regards,
Catalin
Catalin Gheorghe - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”