1. Listview Item identifiers
- Posted by totorangi at hotmail.com Oct 01, 2002
- 385 views
Trying to come to grips with Listviews and have found the archive here useful but still have a problem with Identifiers. I have a listview with several columns of data. I also maintain a sequence that duplicates data in the listview plus has additional data. I want to programmatically update particular rows in the Listview with data from the sequence. I made the now obvious classic mistake of using the Index returned from addLVItem as my key for updating the Listview and it worked until I happened to sort the listview. I use setLVItemText and SetLVImage to update the Listview and I now see that they need the item Identifier and not the row Index. Problem is then how to get the item's Identifier after doing each initial addLVItem. The only way I can find of getting an Identifier is with getLVSelected but this assumes that a row is selected in the first place. This is not the case after the AddLVItem. I have tried a setIndex to programmatically select the row after it is added but this doesn't seem to work on ListViews. Would appreciate tips on this. Thanks Rangi Also, is it possible to view a whole thread on this list ? Search returns useful stuff but I can't find any way of seeing the threads.