Click here to Skip to main content
15,845,785 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I want to read an xml into a datatable.
Though, I seem to be only able to read it into a DataSet.
I would like to get the same result as when I open the xml in Excel.
But instead I am only able to open the xml in a DataSet as it wants to make more tables. Is it possible to read my XML into one datatable?
Or would it be possible to copy a dataset containing multiple parent/child datatables into one large datatable?
This means that parent data would occur in all child data rows.

e.g.

XML
<school>
<schoolID>HighSchool</schoolID>
<students>
<Name>Mark</Name>
<Name>Jane</Name>
</students>
</school>


This would lead to multiple datatables, but I would like to have all data into one datatable. (in my specific file I get 9 datatables when I read the xml to a dataset)
Posted

1 solution

 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900