Jasinski Technical Wiki

Navigation

Home Page
Index
All Pages

Quick Search
»
Advanced Search »

Contributor Links

Create a new Page
Administration
File Management
Login/Logout
Your Profile

Other Wiki Sections

Software

PoweredBy

Using the SelectNodes Method with XML Namespaces - .Net Framework

RSS
Modified on Sun, Nov 30, 2008, 2:00 AM by Administrator Categorized as XML, XSL, and XPath, ·Net Framework
The following code demonstrates how to use the XmlNode.SelectNodes() method with XML Namespaces.

Dim doc As XmlDocument = New XmlDocument()
doc.Load(uxOpenFileDialog.FileName)

Dim nsm As XmlNamespaceManager _
  = New XmlNamespaceManager(doc.NameTable)

nsm.AddNamespace("soap", _
    "http://schemas.xmlsoap.org/soap/envelope/")

Dim soapDataNodes As XmlNodeList = Nothing

soapDataNodes = doc.SelectNodes("soap:Envelope/soap:Body/INPUT", nsm)

ScrewTurn Wiki version 3.0.1.400. Some of the icons created by FamFamFam. Except where noted, all contents Copyright © 1999-2024, Patrick Jasinski.