getElementsByTagName Method (IXMLDOMElement) (Windows Embedded CE 6.0)

1/6/2010

Returns a list of all descendant elements that match the supplied name.

Script Syntax

var objXMLDOMNodeList = oXMLDOMElement.getElementsByTagName(tagName);

Remarks

Ee502103.collapse(en-US,WinEmbedded.60).gifScript Parameters

  • tagName
    String specifying the name of the element to find. The string "*" matches all descendant elements of this element.

Ee502103.collapse(en-US,WinEmbedded.60).gifScript Return Value

Object. Returns IXMLDOMNodeList object containing all elements that match the supplied name.

Ee502103.collapse(en-US,WinEmbedded.60).gifC/C++ Syntax

HRESULT getElementsByTagName(
  BSTR tagName,
  IXMLDOMNodeList** resultList
);

Remarks

Ee502103.collapse(en-US,WinEmbedded.60).gifC/C++ Parameters

  • tagName
    [in] Name of the element to find. The string "*" matches all descendant elements of this element.
  • resultList
    [out, retval] IXMLDOMNodeList object containing all elements that match the supplied name.

Ee502103.collapse(en-US,WinEmbedded.60).gifC/C++ Return Values

  • S_OK
    Value returned if successful.

Ee502103.collapse(en-US,WinEmbedded.60).gifRequirements

Header msxml2.h, msxml2.idl
Library uuid.lib
Windows Embedded CE Windows CE .NET 4.0 and later

Remarks

Elements appear in the order encountered in a preorder traversal of this element's tree.

Note that the IXMLDOMNodeList object is returned even if there are no matches. In this case, the length of the list will be set to zero.

The IXMLDOMNodeList is live and immediately reflects changes to the nodes that appear in the list.

This method applies to the following objects and interfaces:

IXMLDOMElement and IXMLDOMNodeList.

See Also

Reference

XML DOM Methods