HowTo: check for existence of xml attributes to prevent exception event from firing

M

Mike-deerenews

I would like to check for the existence of an attribute in order to prevent
an exception from firing.

Could someone provide an example?

tia
Mike
 
C

Christof Nordiek

"/Employees//@ID" will select nodes under the Employees node containing
the ID attribute

Wouldn't that select the ID attributes of those nodes?
 
M

Morten Wennevik

Well, yeah, but if you use this XPath in SelectNodes the return value
would the nodes those attributes belong to.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top