not able to get element value using groovyUtil
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-22-2008
05:06 PM
05-22-2008
05:06 PM
not able to get element value using groovyUtil
Hello,
I notice that sometime I am not able to get an element's value using groovyutils.
My code looks something like this
def holder = groovyUtils.getXmlHolder( "GetRecommendations - Request 1#Response" )
def imageURL = (holder.getNodeValue()
log.info(imageURL)
This prints out null to the console. However, if I change the Xpath to point to some other elements, I am able to get their value. so some elements work and some do not. I get the xpath by clicking on the XML button in the response. What am I doing wrong.
Ali
I notice that sometime I am not able to get an element's value using groovyutils.
My code looks something like this
def holder = groovyUtils.getXmlHolder( "GetRecommendations - Request 1#Response" )
def imageURL = (holder.getNodeValue(
log.info(imageURL)
This prints out null to the console. However, if I change the Xpath to point to some other elements, I am able to get their value. so some elements work and some do not. I get the xpath by clicking on the XML button in the response. What am I doing wrong.
Ali
1 REPLY 1
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-23-2008
12:48 AM
05-23-2008
12:48 AM
Hi Ali,
hard to know, maybe this is namespace related. Can you show/mail me a response message and xpaths that return null when the "shouldnt"?
regards!
/Ole
eviware.com
hard to know, maybe this is namespace related. Can you show/mail me a response message and xpaths that return null when the "shouldnt"?
regards!
/Ole
eviware.com
