Of course it is possible and not too difficult to achieve either.
foreach (ListViewItem item in lv.Items)
{
foreach (SubListViewItem subItem in item.SubItems)
{
}
}
I recommend to use XDocument and XElement.
Here is a link to MSDN for further help:
XDocument Class Overview[
^]
There are some pretty good examples there.
[Update]
A little example to help you along
ListViewItem row1 = listView1.Items.Add("Row1");
row1.SubItems.Add("Col1_2");
row1.SubItems.Add("Col1_3");
ListViewItem row2 = listView1.Items.Add("Row2");
row2.SubItems.Add("Col2_2");
row2.SubItems.Add("Col2_3");
ListViewItem row3 = listView1.Items.Add("Row3");
row3.SubItems.Add("Col3_2");
row3.SubItems.Add("Col3_3");
ListViewItem row4 = listView1.Items.Add("Row4");
row4.SubItems.Add("Col4_2");
row4.SubItems.Add("Col4_3");
XElement xeRoot = new XElement("Root");
foreach (ListViewItem item in listView1.SelectedItems)
{
XElement xeRow = new XElement(item.Text);
foreach (ListViewItem.ListViewSubItem subItem in item.SubItems)
{
XElement xeCol = new XElement(subItem.Text);
xeRow.Add(xeCol);
}
xeRoot.Add(xeRow);
}