You need to use the WriteXML method of the DataSet like below:
string filename = "myXmlDoc.xml";
MyDataSet.WriteXml(filename,,XmlWriteMode.WriteSchema);
>In Visual FoxPro, we have the ability to add some specific parameters when converting a cursor to an XML string in order to preserve the inline schema. So, at the other end, when reversing the process, we end up with the same structure.
>
>In .Net, from the DataSet, this can be done to convert everything in a XML string:
>
>
>return MyDataSet.GetXML();
>
>
>However, this doesn't preserve the inline schema. So, when I convert that XML into a cursor in Visual FoxPro, I lost the structure. Is there any parameter to specific to the GetXML() call to specify that?
-----------------------------------------
Cathi Gero, CPA
Prenia Software & Consulting Services
Microsoft C# / .NET MVP
Mere Mortals for .NET MVP
cgero@prenia.comwww.prenia.comWeblog: blogs.prenia.com/cathi