My program draws heavily on a winform. During the drawing, the winform is not responding. How to make it responding to my mouse? I want to use another thread to draw to the winform, but I am afraid I am going to meet the infamous cross-threads-access-conrtrol error.
Share
Here is a great MSDN article that might help you: Give Your .NET-based Application a Fast and Responsive UI with Multiple Thread
When I was facing similar problems, it helped me a great deal to understand what to do.
Also, you might want to have a look at Parallel Programming in .NET Framework 4. This series also includes a strategy with calculations that are spread over multiple synchronized threads, all with using out-of-the-box .NET collections. This is not as complicatesd as it may sound. Just give it a try. 🙂
Also, if you have the chance to use the upcoming .NET enhancements, it would be worth to try Asynchronous Programming with Async and Await