I'm using VB.net (2003), and calling the SelectNodes method on an xml document.
If I have a document:
<InqRs>
<DetRs>
<RefInfo>
<RefType>StopNum</RefType>
<RefId>0</RefId>
</RefInfo>
<RefInfo>
<RefType>Id</RefType>
<RefId>0</RefId>
</RefInfo>
</DetRs>
<DetRs>
<RefInfo>
<RefType>StopNum</RefType>
<RefId>0</RefId>
</RefInfo>
<RefInfo>
<RefType>Id</RefType>
<RefId>1</RefId>
</RefInfo>
</DetRs>
</InqRs>
How can I select just for the DetRs that has RefType=Id and RefId=0, ie, the 'first' one above.
I've tried several different attempts, among others:
InqRs/DetRs[RefInfo/RefType='Id' and RefInfo/RefId='0']
InqRs/DetRs[RefInfo/RefType='Id'][RefInfo/RefId='0']
But these select both of the DetRs sections (because of the StopNum RefId of 0, I presume).
Thanks!
Mark