Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. XML / XSL
  4. XPath syntax to get IXMLNode ...

XPath syntax to get IXMLNode ...

Scheduled Pinned Locked Moved XML / XSL
xml
3 Posts 1 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    Andy H
    wrote on last edited by
    #1

    Could someone advise me on the syntax to use to get the IXMLNode whose attribute id="abc" so in the XPath expression used to SelectSinglenode you would specifiy the @id="abc" or whatever the correct syntax is so as to select the Node whose attribute id has the value == "abc". Thanks.

    A 1 Reply Last reply
    0
    • A Andy H

      Could someone advise me on the syntax to use to get the IXMLNode whose attribute id="abc" so in the XPath expression used to SelectSinglenode you would specifiy the @id="abc" or whatever the correct syntax is so as to select the Node whose attribute id has the value == "abc". Thanks.

      A Offline
      A Offline
      Andy H
      wrote on last edited by
      #2

      Basically, I want to locate and return any Node in the XML document which has an attribute id equal to the id I am searching for. I have been trying with XPath's such as: "//*[@id( 'abc' )]" But alas so far I have not found the correct syntax. :confused:

      A 1 Reply Last reply
      0
      • A Andy H

        Basically, I want to locate and return any Node in the XML document which has an attribute id equal to the id I am searching for. I have been trying with XPath's such as: "//*[@id( 'abc' )]" But alas so far I have not found the correct syntax. :confused:

        A Offline
        A Offline
        Andy H
        wrote on last edited by
        #3

        I managed to get this to work thus: "//*[@id='" + sURI + "']" Thanks

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups