all groups > dotnet xml > august 2005 >
You're in the

dotnet xml

group:

Parameters in XPath Query .


Parameters in XPath Query . Speed
8/29/2005 9:49:01 PM
dotnet xml:
I have a following xml file :
<Bitmaps>
<BITMAP id="1">
<BITMAP id="2">
<BITMAP id="3">
</Bitmaps>

if i need to go the node BITMAP id = 2 directly can i use the XPath
query as
string query = "/Bitmaps/Bitmap[@id = 2]";
Re: Parameters in XPath Query . Dimitre Novatchev
8/30/2005 8:58:16 PM

[quoted text, click to view]

No.

But one XPath expression that will select the wanted node is:

/Bitmaps/BITMAP[@id = 2]


Cheers,
Dimitre Novatchev

AddThis Social Bookmark Button