Quoting Ross Craig <ro...@northern-lights.com>:


Maybe you need a /text() in the path.


Just a guess.


Hi Ross,

Thanks for that tip.

I didn't think I would need to add text() to the XPath expression when calling XDOMLocate function because 1) the XDOMLocate is meant to locate a node and the function call was succesful and 2) there is a separate XDOMGetNodeValue function.

I thought the only situation I would ever need to use text() in when evaluating an XPath expression by calling XDOMEvaluate or when using predicate to select nodes containing specific text string.

Anyway. I just did a test to see how XDOMEvaluate function would react if I remove /text() from the XPath expresion. And to my surprise, XDOMEvaluate actually returned a value to /test/name node without text()

So it looks like text() is not required when using XDOMEvaluate to retrive a node's text value but it is required when using XDOMLocate and XDOMGetNodeValue.

Hmm..  That doesn't make sense to me.
Nevertheless.  At least I can move on and do other parts of programs.

Thanks again for the information.
U2-Users mailing list

Reply via email to