Here's the methd I use to "recreate" the list :
Notice that the listctrl itself isn't deleted/removed (unlike in the sample, which is doing other things). Calling ClearAll() will remove *all* the data *and* the column headings. So the first thing we do is re-apply the headings.
Then the code iterates through a list of data, and calls the previously mentioned method to actually add the data to the list.
Remember, this is just one way to do everything.
But basically, the steps involved are :
* Clear your list
* Add headers if you need them
* Insert your row items.
:o)
Method PopulateIndexes(table:TDBATable) indexesList.ClearAll() SetIndexHeadings() If table Then Local list:TList = table.ListIndexes() Local i:Int = 0 For Local index:TDBAIndex = EachIn list index.InsertIntoList(i, indexesList) i:+ 1 Next End If End Method
Notice that the listctrl itself isn't deleted/removed (unlike in the sample, which is doing other things). Calling ClearAll() will remove *all* the data *and* the column headings. So the first thing we do is re-apply the headings.
Then the code iterates through a list of data, and calls the previously mentioned method to actually add the data to the list.
Remember, this is just one way to do everything.
But basically, the steps involved are :
* Clear your list
* Add headers if you need them
* Insert your row items.
:o)