Click to return to the XML (Extensible Markup Language) home page    
IXMLDOMNode::firstChild P...     IXMLDOMNode::insertBefore...     IXMLDOMNode Interface    
Web Workshop  |  XML (Extensible Markup Language)

IXMLDOMNode::hasChildNodes Method


Returns true if this node has children.

Visual Basic Syntax

boolValue = oXMLDOMNode.hasChildNodes

C/C++ Syntax

HRESULT hasChildNodes(
    VARIANT_BOOL *hasChild);

Parameters

hasChild
[out] True is returned if this node has children.

C/C++ Return Value

S_OK
Value returned if successful.
S_FALSE
Value when VARIANT_FALSE is returned. 
E_INVALIDARG
Value returned if hasChild is null.

Remarks

This method offers a fast way to determine whether a node has children. This method always returns false for nodes that, by definition, cannot have children: the IXMLDOMCDATASection, IXMLDOMComment, IXMLDOMNotation, IXMLDOMProcessingInstruction, and IXMLDOMText nodes.



Back to topBack to top

Did you find this topic useful? Suggestions for other topics? Write us!

© 1999 Microsoft Corporation. All rights reserved. Terms of use.