KNOWLEDGE BASE
Log In    |    Knowledge Base    |    4D Home
Tech Tip: How to force a process to IDLE
PRODUCT: 4D | VERSION: 2004 | PLATFORM: Mac & Win
Published On: January 9, 2007
Your current browser may not allow you to download the asset. We recommend Mozilla Firefox or Google Chrome.
Log In

When running compiled or when a long batch task is being executed, 4D might not share the CPU time with other 4D processes. In this situation you would normally use the IDLE command. However, this command does not always execute an idle. 4D's scheduler always checks to see if all processes have used at least one tick of CPU time and then gives control to the next process only when that process used at least one tick. If you need to force an idle, you can execute DELAY PROCESS(Current process;0). This statement will not delay your process but will force an idle. This means that your process will automatically give the control to the next process and will nit use one tick of CPU time.

Reminder: 1 tick is 1/60th of a second.