NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

DataSet.XmlDocument

Gets the XML document for the DataSet.

[Visual Basic]
Public ReadOnly Property XmlDocument As XmlDocument
[C#]
public XmlDocument XmlDocument {get;}
[C++]
public: __property XmlDocument* get_XmlDocument();
[JScript]
public function get XmlDocument() : XmlDocument;

Property Value

An XmlDocument.

Remarks

The XmlDocument provides an interface to save and load the information contained in a DataSet as an XML document. Through the property, you can access other methods of the XmlDocument.

Example [Visual Basic]

The following example returns the XML document for a DataSet associated with a System.WinForms.DataGrid control.

[Visual Basic]

Private Sub GetXMLDocument()
   Dim ds As DataSet
   ' Presuming the DataGrid is bound to a DataSet.
   ds = DataGrid1.DataSource
   Dim myDoc As xml.XmlDocument
   myDoc = ds.XmlDocument
   Console.WriteLine(mydoc.Xml)
End Sub

See Also

DataSet Class | DataSet Members | System.Data Namespace | XmlDocument