|
Borland C ++ Builder FAQ
|
||
| The content | The last update: 12/12/2008 | |
|
How to assign to the program other priority? The author: KAV HANDLE ProcessHandle, ThreadHandle; DWORD ProcessID = GetCurrentProcessId (); ProcessHandle = OpenProcess (PROCESS_ALL_ACCESS, false, ProcessID); SetPriorityClass (ProcessHandle, HIGH_PRIORITY_CLASS); ThreadHandle = GetCurrentThread (); SetThreadPriority (ThreadHandle,THREAD_PRIORITY_TIME_CRITICAL); |