THREAD GET PRIORITY statement  

Purpose

Retrieve the Priority Value for a threads.

Syntax

THREAD GET PRIORITY hThread TO lResult&

Remarks

THREAD GET PRIORITY retrieves the priority value for the thread specified by the thread handle (hThread).  The thread handle is returned by the THREAD CREATE statement at the time the thread is created.  If hThread is zero (0), the thread which is currently executing is presumed.  The retrieved priority value is assigned to the long or dword variable designated by lResult&.  A thread ID cannot be used in place of a thread handle.

    The thread priority value is one of the following:

    %THREAD_PRIORITY_IDLE         = -15
  %THREAD_PRIORITY_LOWEST       =  -2
  %THREAD_PRIORITY_BELOW_NORMAL =  -1
  %THREAD_PRIORITY_NORMAL       =   0
  %THREAD_PRIORITY_ABOVE_NORMAL =  +1
  %THREAD_PRIORITY_HIGHEST      =  +2
  %THREAD_PRIORITY_TIME_CRITICAL= +15

See also

PROCESS GET PRIORITY, PROCESS SET PRIORITY, THREAD CREATE, THREAD SET PRIORITY