Hello,

Is there an easy way to retrieve the text from a subitem given the subitems
position?

I have this code that populates an excel spreadheet. This works nicely
until they reorder the columns

I wrote a function that will retrieve the position given the index but I
can't seem to get the text of this position

With exWorkSheet
.Cells(i, 1) = oItem.ListSubItems(1).Text
.Cells(i, 2) = oItem.ListSubItems(2).Text
.Cells(i, 3) = oItem.ListSubItems(3).Text
.Cells(i, 4) = oItem.ListSubItems(4).Text
.Cells(i, 5) = oItem.ListSubItems(5).Text
.Cells(i, 6) = oItem.ListSubItems(6).Text
End With


Thanks for any help

Greg