Microsoft XML Core Services (MSXML) 5.0 for Microsoft Office - DOM Reference

parsed Property

Indicates the parsed status of the node and child nodes.

[Script]

Script Syntax

boolValue = oXMLDOMNode.parsed;

Example

The following script example displays whether or not the top-level node (root) and all its descendants are parsed.

var xmlDoc = new ActiveXObject("Msxml2.DOMDocument.5.0");
var root;
xmlDoc.async = true;
xmlDoc.load("books.xml");
if (xmlDoc.parseError.errorCode <> 0) {
   var myErr = xmlDoc.parseError;
   alert("You have error " + myErr.reason);
} else {
   root = xmlDoc.documentElement;
   alert(root.parsed);
}
[Visual Basic]

Visual Basic Syntax

boolValue = oXMLDOMNode.parsed

Example

The following Microsoft® Visual Basic® example displays whether the top-level node (root) and all its descendants are parsed.

Dim xmlDoc As New Msxml2.DOMDocument50
Dim root As IXMLDOMElement
xmlDoc.async = True
xmlDoc.Load ("books.xml")
if (xmlDoc.parseError.errorCode <> 0) {
   var myErr = xmlDoc.parseError;
   alert("You have error " + myErr.reason);
} else {
   Set root = xmlDoc.documentElement
   MsgBox root.parsed
End If
[C/C++]

C/C++ Syntax

HRESULT parsed(
    VARIANT_BOOL *isParsed);

Parameters

isParsed [out, retval]
True if this node and all descendants have been parsed; False if any descendants remain to be parsed.

C/C++ Return Values

S_OK
The value returned if successful.
E_INVALIDARG
The value returned if the isParsed parameter is Null.

Remarks

Boolean. The property is read-only. During asynchronous access, not all of the document tree may be available. Before performing some operations, such as XSLT or pattern-matching operations, it is useful to know whether the entire tree below this node is available for processing.

This member is an extension of the World Wide Web Consortium (W3C) Document Object Model (DOM).

To view reference information for Visual Basic, C/C++, or Script only, click the Language Filter button Language Filter in the upper-left corner of the page.

See Also

XSLT Reference

Applies to: IXMLDOMAttribute | IXMLDOMCDATASection | IXMLDOMCharacterData | IXMLDOMComment | DOMDocument | IXMLDOMDocumentFragment | IXMLDOMDocumentType | IXMLDOMElement | IXMLDOMEntity | IXMLDOMEntityReference | IXMLDOMNode | IXMLDOMNotation | IXMLDOMProcessingInstruction | IXMLDOMText