Share via


Program with DOM in C-C++

 

This tutorial is intended for C/C++ developers interested in writing XML applications using the DOM APIs as implemented in Microsoft XML Core Services (MSXML). It includes a series of simple examples written in C. The objective is to provide a quick and practical orientation, so that you can start to write your own XML applications.

These demonstrations are task-oriented, and are simplified for clarity. Therefore, their implementation is not always optimized.

This tutorial consists of the following demonstrations.

How Do I? Description
Get Ready to Work with MSXML (C/C++) Discusses the requirements for using MSXML, and describes how to install the MSXML components.
Set Up My Visual C++ Project Demonstrates how to set up a Visual C++ project to write your own XML applications in C/C++ using the XML DOM.
Include Headers and Libraries Manually Performs the same functions as the Load an XML DOM Object from an XML File example, but incorporate headers and libraries manually.
Load an XML DOM Object from an XML File (C/C++) Demonstrates how to create an XML DOM instance and load its content from an external XML data file.
Save an XML DOM Object to a File (C/C++) Demonstrates how to serialize an XML DOM object in a text file.
Perform XSL Transformations (C/C++) Demonstrates how to perform XSL Transformations.
Create an XML DOM Object Dynamically (C/C++) Demonstrates how to create an XML DOM object programmatically, including processing instructions, comments, elements, attributes, CDATA sections, and text nodes.
Query XML DOM Nodes (C/C++) Demonstrates how to query a DOM node or node-set using XPath expressions.
Validate XML (C/C++) Demonstrates how to validate XML documents against an XML schema as well as how to validate document node fragments.
Manage Object Lifetime Using Reference Counting on Interface Pointers (C/C++) Demonstrates how to manage the life-time of DOM objects when using raw interface pointers.
Use OnReadyStateChange in Visual C++ Applications Discusses how to use the UseOnReadyStateChange event.