I used to use MsgWaitForMultipleObjects with success to wait on the event’s handle and pump messages at the same time.
However I don’t have that procedure on Windows Mobile.
The situation is as follows:
- I open form which displays some animation
- Run thread
- Wait until thread finishes (when it sets event to Set())
Without pumping messages I will not see the animation on the form as waiting for the thread using WaitOne for instance, is blocking everything …
How can I achieve the same functionality on Windows Mobile?
Thanks
A simple way to achieve what you’re looking for is to use the BackgroundWorker class that’s part of the OpenNETCF framework
It’s essentially a functional copy of the System.ComponentModel.BackgroundWorker class from the full .NET framework.
Execute as follows:
Below is an example adapted from the MSDN backgroundworker class documentation that may point you in the right direction.