Given this XML, I want to retrieve a XmlNodeList
of <member>
nodes from <group>
nodes whose <id>
matches 'Tech'. The matching should be case-insensitive.
<groups>
<group>
<id>Tech</id>
<members>
<member>johndoe</member>
<member>janedoe</member>
<member>robdoe</member>
</members>
</group>
<group>
<id>Support</id>
<members>
<member>johnfoe</member>
<member>janefoe</member>
<member>robfoe</member>
</members>
</group>
</groups>
I've tried this, expecting to get the "doe members", but it doesn't seem to return any results.
// assume groupName='tech'
_document.SelectNodes("//groups/group[translate(id,'abcdefghijklmnopqrstuvxyz','ABCDEFGHIJKLMNOPQRSTUVXYZ')='" + groupName.ToUpper() + "']/members/member");