469,117 Members | 1,364 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,117 developers. It's quick & easy.

Map ListView.Columns[].Index to ListView.Items[].SubItems index


I'm having a index problem with ListView SubItems. If I add multiple
columns to the listview and then add items with associated subitems,
the ListView displays fine. Then if I delete a column via
ListView.Columns.RemoveAt() then the ListView still displays fine.
However, if I grab a subitem value via

listView.Items[itemIndex].SubItems[column.Index].Text

Then I get the Text of the wrong column.

If the ListView internally knows what Column is associated with which
SubItem, how can we find out after columns have been added/removed?

Thanks,

Sam
Nov 16 '05 #1
0 2270

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

1 post views Thread by andrewcw | last post: by
reply views Thread by Andrew | last post: by
12 posts views Thread by Dennis | last post: by
1 post views Thread by Joe | last post: by
1 post views Thread by plmanikandan | last post: by
1 post views Thread by samoore33 | last post: by
1 post views Thread by CARIGAR | last post: by
reply views Thread by zhoujie | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.