Archive

Posts Tagged ‘xml’

Load DataSet from xml file.

May 20th, 2009 wiley No comments

Load DataSet from xml file:

The file is called users.xml. The example structure of xml file is:

<users>
  <user>
    <name>My Name</name>
  </user>
</users>

Code to load xml file into DataSet:

DataSet ds = new DataSet("user");
...
string filePath = "users.xml";
ds.ReadXml(filePath);

The value of the filePath is the full path to the file users.xml.


Unique visitors to post: 33

Categories: C#, XML Tags: , ,
Google Analytics integration offered by Wordpress Google Analytics Plugin