How do I access the XPath within an XML Node?
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-12-2019
01:59 PM
03-12-2019
01:59 PM
How do I access the XPath within an XML Node?
I am trying to access an attribute within an XML node. How would I do this?
<data:TransactionAdd AccountID="?">
I need to access the AccointID attribute, but when I map to TransactionAdd the XML is going after the TransactionAdd header.
Looks like this <data:TransactionAdd AccountID="?">XPATH LEADS HERE<Optional>
How do I access the variable AccountID via XPath?
1 REPLY 1
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-13-2019
01:59 AM
03-13-2019
01:59 AM
Did you try this approach?
def gutils = new com.eviware.soapui.support.GroovyUtils( context ); def holder = gutils.getXmlHolder("Request_Name#Response"); def accountId = holder.getNodeValue("//data:TransactionAdd/@AccountID");
