Processing XML by Using the Document Object Model

So far we have discussed forward-only reading and writing of XML documents. The XML Document Object Model (XML DOM) creates an in-memory hierarchical view of the XML document that can be navigated in any direction. The XML DOM can be used to create, modify, and parse an XML document.

The XML DOM tree is made up of nodes. In the .NET Compact Framework, these nodes are represented by an abstract class named XmlNode. Each type of node is represented by an implementation of the XmlNode class. For instance, an element node is represented by the XmlElement class, which implements the XmlNode abstract class.

The XmlDocument class represents the very top of the XML DOM tree. The nodes underneath the XmlDocument ...

Get Microsoft® .NET Compact Framework Kick Start now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.