Wednesday, 7 August 2013

how to load a datagridview with my data from xml,C#(VS2012)

how to load a datagridview with my data from xml,C#(VS2012)

I have this xml:
<container_1 attr1="..." attr2="..." attr3="...">
<rekord_1>
<type_1 attr1="..." attr2="..." ... />
<type_2 attr1="..." attr2="..." ... />
</rekord_1>
<rekord_2>... </rekord_2>
.
.
<rekord_N> ... </rekord_N>
</container_1>
I can parse it as I want and show in console app(used
XMLElements,XMLNodeLists and few loop) but I want to make an app with gui
and table view. My form app could read the xml,but it can handle only 1
tag yet.For example if I get the container_1 tag,it puts out only
container_1's attributes by itself,but I want to show the rekords too
under the container_1 in table view.
I want to make it able to parse like my older program in console.
How can I get out the data from my xml that I can be able to work with
elements/attributes? Because I want to set theirs place in table view.
Which dokumentation should I read? or Is there some example wich could be
usefull to me?
Thanks for help! And sorry for my bad english.

No comments:

Post a Comment