Update Listview from threads in a Threadpool in VB.net or C#
Posted on 2009-07-15
I'm trying to update a listview from a threads in a threadpool. Sequentially updating the listview is too slow, so I wanted to use threads. Just using a single worker thread using a delegate to update the UI is still too slow. So I want to spawn as many threads as rows in the listview(several hundred). This will likely swamp the CPU, so I want to put them into a threadpool. I've used threadpools before, but mainly just to insert data into databases, never to update a UI.
How do you update the UI from threads in a threadpool?
I'm using VB.NET 2005. I'm also not using virtual listviews. I would even take a C# method.