| 9/4/2006
ReadXMLDocumentsVisualBasicAndXPathXPathNavigator.zip
The .NET 2.0 XmlNavigator class
provides a cursor model for navigating and editing XML data. This
article and download provide an introduction to using the XPathNavigator
to read XML documents.
The download contains two examples:
one that reads an XML document that contains a default namespace
and one that reads and XML document that does not contain a default
namespace.
An XPathNavigator object is created from a class that implements the IXPathNavigable interface such as the XPathDocument and XmlDocument classes.
' Declare a variable named
theXPathNavigator of type XPathNavigator.
Dim theXPathNavigator
As XPathNavigator
' Call the peopleXmlDocument object's
CreateNavigator method
' assigning the resulting
XPathNavigator object to theXPathNavigator variable.
theXPathNavigator = peopleXmlDocument.CreateNavigator
Click the link above to download Visual Basic source code in a Visual Studio 2005 solution which demonstrates how to use the XPathNavigator class to read XML documents.
For more information visit:
XPath Navigator Class .NET 2.0
Get Dot Net Code is a web site full of free and pay for use Visual Basic source code for Visual Basic programmers.
|