![]() |
|
#1
|
||||
|
||||
XSD to Data Table in VB.NETFriends, I have an xsd which contains a single element along with it's attributes. I need a method to create a data table to match that element according to the way that element is defined in xsd. say for an example: I have defined the element box in xsd file with attributes: length, width, height now I want to make a data table which will be able to store box type rows. in other words, the resulting table should have columns: height, width, length I really need this help soon because at the moment I am wasting a lot of my time on hard coding this (column by column for the table) Thanks in advance! -- Menol -- |
|
#2
|
|||
|
|||
Re: XSD to Data Table in VB.NETCurious as to why you want to create the DataTable from the xsd. I'm not sure how to do that.
However, its quite easy to create a datatable from xml. I knocked up a little test. Xml Data held in 'XmlFile1.xml' HTML Code:
Load the xml C-SHARP / C# Code:
You could use the xsd and .NET Framework (XmlValidatingReader) to validate the data before you read it into the DataSet, that way you know that the data and columns created in the DataTable conform to your xsd. Hopefully that helps... |
Recent GIDBlog
Flickr uploads of IA pictures by crystalattice
| Thread Tools | Search this Thread |
| Rate This Thread | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| [Include] Doubly-linked List | dsmith | C Programming Language | 6 | 14-Apr-2006 13:12 |
| Strange C++ code memory leakage problem | gaoanyu | C++ Forum | 7 | 04-Nov-2005 08:09 |
| [CONTEST?]Data Structure Test | dsmith | C Programming Language | 2 | 06-Jun-2004 15:13 |
Network Sites: GIDNetwork · GIDWebHosts · GIDSearch · Learning Journal by J de Silva, The