XMLNodes Property

Microsoft Word Visual Basic

XMLNodes Property

Returns an XMLNodes collection that represents the collection of all XML elements within a document or in a selection or range— including those elements that are only partially within the selection or range.

expression.XMLNodes

expression    Required. An expression that returns one of the objects in the Applies To list.

Example

The following example returns the first XML node in the active document.

    Dim objNode As XMLNode
    
Set objNode = ActiveDocument.XMLNodes.Item(1)