View Single Post
 
Old 06-01-2015, 02:22 PM
polaco19 polaco19 is offline
Newcomer
 
Join Date: Jun 2015
Posts: 1
Default (VS2005) Load an special XML File into a Datagridview

I'm looking for a long time a solution for my problem with no results:

I have this kind of XML file:

Code:
<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
<Job xmlns="http://xxxx.com" CreationDate="2015-04-07T17:38:44" DocumentCount="1" Name="BarCodes_E">

  <Document Name="Doc001">
    <Data Format="Text" Name="ID01">Data 1</Data>
    <Data Format="Text" Name="ID02">Data 2</Data>
    <Data Format="Text" Name="ID03">Data 3</Data>
    <Data Format="Text" Name="ID04">Data 4</Data>
    <Data Format="Text" Name="ID05">Data 5</Data>
  </Document>
  
    <Document Name="Doc002">
    <Data Format="Text" Name="ID01">Data 1</Data>
    <Data Format="Text" Name="ID02">Data 2</Data>
    <Data Format="Text" Name="ID03">Data 3</Data>
    <Data Format="Text" Name="ID04">Data 4</Data>
    <Data Format="Text" Name="ID05">Data 5</Data>
  </Document>

    <Document Name="Doc003">
    <Data Format="Text" Name="ID01">Data 1</Data>
    <Data Format="Text" Name="ID02">Data 2</Data>
    <Data Format="Text" Name="ID03">Data 3</Data>
    <Data Format="Text" Name="ID04">Data 4</Data>
    <Data Format="Text" Name="ID05">Data 5</Data>
  </Document>
  
</Job>
And i need to load the data by rows into a Datagridview and then the selected rows export them into a new XML file, but the main problem is import the data.

The datagridviw should look like this:

|chckbox| Name | ID01 | ID02 | ID03 | ID04 | ID05 |
| ..OK.. |Doc001|Data 1|Data 2|Data 3|Data 4|Data 5|
| ..NO.. |Doc002|Data 1|Data 2|Data 3|Data 4|Data 5|
| ..OK.. |Doc003|Data 1|Data 2|Data 3|Data 4|Data 5|
Reply With Quote