Hello,
Using the following XML file, I would like to be able to
filter using an XPath
to the nodes where Menu = Yes and Form Name = frmMainMenu
<?xml version="1.0" standalone="yes"?>
<productX>
<Table Name="mnuFile">
<value>myFile</value>
<Parent></Parent>
<Menu>YES</Menu>
<Form Name="frmMainMenu" />
</Table>
<Table Name="lblTest">
<value>myTest</value>
<Parent></Parent>
<Menu>No</Menu>
<Form Name="frmMainMenu" />
</Table>
<Table Name="mnuExit">
<value>myExit</value>
<Parent></Parent>
<Menu>YES</Menu>
<Form Name="frmMainMenu" />
</Table>
</productX>
I am using the following XPath
"//Table[./@Menu=YES and ./Form/@Name = 'frmMainMenu']"
This returns no Nodes when using the following code:
strXPath = "//Table[./@Menu=YES and ./Form/@Name
= 'frmMainMenu']"
XMLNodeIterator= xmlNavigator.Select(strXPath)
After running this code the XMLNodeIterator.Count = 0.
Can anyone please help me by providing me with the correct
XPath to perform this filter.
Regards,
Felicity