The important methods of a DataSet class for XML are :
1. GetXml Method
2. GetXmlSchema Method
3. InferXmlSchema Method
4. WriteXml Method
5. WriteXmlSchema Method
6. ReadXml Method
7. ReadXmlSchema Method
There are 2 ways you can do this:
1. using the ExecuteReader method with "CommandBehavior.CloseConnection" parameter
2. Putting the Connection object with Using statement