Share via


MoveToElement Method

[This documentation is for preview only, and is subject to change in later releases. Blank topics are included as placeholders.]

When overridden in a derived class, moves to the element that contains the current attribute node.

Namespace:  System.Xml
Assembly:  System.Xml (in System.Xml.dll)

Syntax

'Declaration
Public Overridable Function MoveToElement As Boolean
public virtual bool MoveToElement()
public:
virtual bool MoveToElement()
abstract MoveToElement : unit -> bool 
override MoveToElement : unit -> bool 
public function MoveToElement() : boolean

Return Value

Type: System. . :: . .Boolean
true if the reader is positioned on an attribute (the reader moves to the element that owns the attribute); false if the reader is not positioned on an attribute (the position of the reader does not change).

Remarks

Use this method to return to an element after navigating through its attributes. This method moves the reader to one of the following node types: Element, DocumentType, or XmlDeclaration.

.NET Framework Security

See Also

Reference

XmlReader Class

System.Xml Namespace