In order to know the Element is a Node is TextNode, or other type, can IXMLDOMNode:: nodeType to obtain, this is an enumerated type, the following values (this also can be seen above, the XML text and XML are not covered all the elements): NODE_ELEMENT (1) NODE_ATTRIBUTE (2) NODE_TEXT (3) NODE_CDATA_SECTION (4) NODE_ENTITY_REFERENCE (5) NODE_ENTITY (6) NODE_PROCESSING_INSTRUCTION (7) NODE_COMMENT