phone_guy
January 14th, 2005, 12:04 PM
My application is importing data from a text file and is very processor intensive. I'd like to yield the process if there are any pending messages on my application's thread.
In MFC I was able to yield the app in this way:
MSG msg;
while (::PeekMessage(&msg, NULL, 0, 0, PM_NOREMOVE))
AfxGetThread()->PumpMessage();
Anyone know how to do this in .NET?
In MFC I was able to yield the app in this way:
MSG msg;
while (::PeekMessage(&msg, NULL, 0, 0, PM_NOREMOVE))
AfxGetThread()->PumpMessage();
Anyone know how to do this in .NET?