Tuesday, February 12, 2008

Create typed dataset from xml schema

Practical Issue:

I have a class library project and have added a simple xml schema file.

Here are my questions:
How do you create the dataset from the xml schema file? Do I have to use the xsd.exe from the command line to create the dataset or is there a method to create the dataset from inside the VS 2005 IDE?

My Guidence:

http://aspnet.4guysfromrolla.com/articles/052902-1.aspx

Introduction:

With classic ASP, if one wanted to display XML data on an ASP Web page they had a number of options. The simplest option, in my opinion, would be to use the XML support present in ADO 2.5 to populate a Recordset with XML data, and then to display the Recordset data as you would on any other page. Another option would be to use the MSXML component to iterate through the contents of the XML document, perhaps using XSLT. Similarly, if you wanted to write a collection of data, such as database results, to an XML stream would be, again, to use the Recordset object or to use the MSXML component.

No comments: