Mega Code Archive

 
Categories / Delphi / API
 

Yielding cycles to other applications

Question: How can I yield to the system during a lengthy operation without allowing message processing to continue in my application? Answer: Call the Windows API Sleep() function passing zero as a parameter.