CeSetThreadQuantum (Windows CE 5.0)

Windows CE 5.0
Send Feedback

This function sets the time quantum for the specified thread.

BOOL CeSetThreadQuantum(
  HANDLE hThread, 
  DWORD dwTime
); 

Parameters

hThread
[in] Handle to a thread.
dwTime
[in] Specifies the quantum or time slice, measured in milliseconds, required for the thread to run.

If 0 (zero) is specified, the thread runs to completion.

By default, every thread in the system has a default quantum defined by the OEM unless it is set to a different value by a call to this function.

If the value is not redefined by the OEM, the value is 100 milliseconds.

Return Values

TRUE indicates success.

FALSE indicates failure.

To get extended error information, call GetLastError.

Remarks

As long as no higher priority threads are ready to run, a thread runs for the length of the specified quantum.

Note   The default 100-millisecond quantum is a change from earlier Windows CE releases, which used a 25-millisecond tick count to schedule threads.

Requirements

OS Versions: Windows CE 3.0 and later.
Header: Winbase.h.
Link Library: Coredll.lib.


Send Feedback on this topic to the authors

Feedback FAQs

© 2006 Microsoft Corporation. All rights reserved.


Show: