Generate container instances at runtime for desktop app

Hi all - I am looking for an example as an alternative to using a listbox to display database results for a few records at a time by displaying results on container controls and generating the number of instances needed after performing a query. So if 7 records were returned, 7 container instances would be stacked with results of each record contained within. I’d like to leverage the ability of containers to include tab controllers, list boxes, etc which can’t be done inside a listbox itself as far as I know. Maybe someone has done something similar and can point me in the right direction? Or 3rd party plug-in? Thanks!

The DownloadContainer example creates a scrolling Canvas of DownloadContainers. Perhaps it could be adapted to instead be a scrolling list of DBResultContainers that are designed the way you want.


Thanks Paul - this looks promising! Weird I had missed that example this whole time

@Paul Lefebvre , In playing with the example, I think I found a bug I have been unable to resolve. Create 10 ‘downloads’, then click ‘cancel’ on items 1, 4, and 5. Finally click ‘Clean Up’. When the canvas re-draws, it is leaving a large space toward the top. Clicking ‘Clean Up’ once or twice more fixes the issue. I thought it may be a refresh issue, but several attempts at refreshing the canvas have not done the trick. Any insight?

Could just be a math problem with the code that figures out where to draw the containers. I’ll take a peek when I’m back in the offfice.