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!

korr
Posts: 48
Joined: Tue Sep 09, 2014 3:13 pm

XML Element Search

Maybe I'm not understanding this correctly, but Im thinking there is a bug in the xml search for elements. Say I have the following XML :

Code: Select all

<connection>
	<server>address</server>
	<speed>0</speed>
	<username>User1</username>
	<username>User2</username>
	<keepAlive>No</keepAlive>
</connection>
To do a search and retrieve the text for <keepAlive> I have to use "Element has index in parent" and the value in that search has to be "4" because its the 5th element, as well as be encapsulated by looking for "keepAlive". Shouldn't it work that the value needs to be "0" as it the first instance of "keepAlive" that I want? If I add another <username> element I then need to increase the value for the "keepAlive" search to obtain ANY result.
Dan
Posts: 4530
Joined: Wed Apr 24, 2013 3:51 pm

Re: XML Element Search

Hello,

Maybe you can find a way to create the .xml file. e.g. having the following structure:

Code: Select all

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<connection>
   <keepAlive value="attributeValue">No</keepAlive>
</connection>
Having the .xml with this structure, you will be able to get the element text, as you can see below:
Edit XML Locator.png
Edit XML Locator.png (17.36 KiB) Viewed 2987 times
Please let me know if this approach is suitable for you.

Best regards,
Dan
Dan Ghiorghita - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
korr
Posts: 48
Joined: Tue Sep 09, 2014 3:13 pm

Re: XML Element Search

We are using an xml that gets exported from a third party program, so while we could manually change the xml it wouldnt work to automate builds.

Return to “Common Problems”