Hi,

I've created a dataset and then I write the dataset to a database by
taking the XML string of the dataset and storing that as one column in the
database (because the dataset is variable).

In other words, I call GetXml on the dataset, and store this string.

Now I want to go the other way... I want to take the string and convert it
back to a dataset but there doesn't seem to be an easy way to do this.
What I'm doing is loading it into an XML document like follows:

 string XMLData = myDataView[0].Row["XMLData"].ToString();
 XmlDataDocument myXMLData = new XmlDataDocument();
 myXMLData.LoadXml(XMLData);

Then I iterate through the data document and rebuild the dataset.

It seems to me that if it was so simple to call GetXml on a dataset, there
should be some simple way of getting the Xml back into a dataset.  Maybe
I'm missing something.

FYI... the ultimate goal is to display it in a datagrid so I would be
happy to skip the dataset altogether.

Thank you,

Karen

You can read messages from the DOTNET archive, unsubscribe from DOTNET, or
subscribe to other DevelopMentor lists at http://discuss.develop.com.

Reply via email to