Description:-
find XmlNode
from Xml File in Dynamics ax Here we will find xml node from XmlDocument. If you
want to find single XmlNode that you can find it by using selectSingleNode
using XmlDocument class. Here is the example of finding XmlNode from xml file.
Code:-
static void XMLNodeFind(Args _args) { str xml; XmlDocument xmlDoc; XmlNode xmlNode; ; xml = @'<ParentNode> <Node> <Name1>2003</Name1> <Name2>20030630</Name2> <Name3>20140225</Name3> <Name4>46944000</Name4> <Name5>94750099</Name5> </Node> </ParentNode>'; xmlDoc = XmlDocument::newXml(xml); xmlNode = xmlDoc.selectSingleNode('//Name1'); info(xmlNode.innerText()); }
Thanks for comments.....