This documentation is archived and is not being maintained.

XmlTextReader.Namespaces Property

Gets or sets a value indicating whether to do namespace support.

[Visual Basic]
Public Property Namespaces As Boolean
public bool Namespaces {get; set;}
public: __property bool get_Namespaces();
public: __property void set_Namespaces(bool);
public function get Namespaces() : Boolean;
public function set Namespaces(Boolean);

Property Value

true to do namespace support; otherwise, false. The default is true.


Exception Type Condition
InvalidOperationException Setting this property after a read operation has occurred (ReadState is not ReadState.Initial).


This property determines whether the reader supports the W3C Namespaces in XML recommendation located at

The Namespaces property cannot be set after a read operation has occurred.


Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family, .NET Compact Framework, Common Language Infrastructure (CLI) Standard

See Also

XmlTextReader Class | XmlTextReader Members | System.Xml Namespace