Memento

Memento

  • NA
  • 111
  • 133.3k

C# - winforms - How to populate multicolumn DataGridVew via reading xml node by node

May 16 2012 8:23 AM
C# - winform
I have a multicolumn DataGridView (dgv01) and successfully filled first column by xml nodes:
XmlDocument file01;
XmlNode node;
string path01 = Application.StartupPath + "\\History.xml";
file01 = new XmlDocument();
file01.Load(path01);
node = file01.DocumentElement;
foreach (XmlNode node1 in node.ChildNodes)
if (node1.Name == "abc")
{
 dgv01.Rows.Add(node1.InnerText);
}
But, i also want to populate second and third dgvColumns by some other nodes, and not via creating DataSet, but reading node by node, just as with first column.
What is the way, pls?
Thanks in advance.


Answers (2)