GetUmsCompletionListEvent function (winbase.h)

Retrieves a handle to the event associated with the specified user-mode scheduling (UMS) completion list.

Warning

As of Windows 11, user-mode scheduling is not supported. All calls fail with the error ERROR_NOT_SUPPORTED.

Syntax

BOOL GetUmsCompletionListEvent(
  [in]      PUMS_COMPLETION_LIST UmsCompletionList,
  [in, out] PHANDLE              UmsCompletionEvent
);

Parameters

[in] UmsCompletionList

A pointer to a UMS completion list. The CreateUmsCompletionList function provides this pointer.

[in, out] UmsCompletionEvent

A pointer to a HANDLE variable. On output, the UmsCompletionEvent parameter is set to a handle to the event associated with the specified completion list.

Return value

If the function succeeds, it returns a nonzero value.

If the function fails, the return value is zero. To get extended error information, call GetLastError.

Remarks

The system signals a UMS completion list event when the system queues items to an empty completion list. A completion list event handle can be used with any wait function that takes a handle to an event. When the event is signaled, an application typically calls DequeueUmsCompletionListItems to retrieve the contents of the completion list.

The event handle remains valid until its completion list is deleted. Do not use the event handle to wait on a completion list that has been deleted or is in the process of being deleted.

When the handle is no longer needed, use the CloseHandle function to close the handle.

Requirements

Requirement Value
Minimum supported client Windows 7 (64-bit only) [desktop apps only]
Minimum supported server Windows Server 2008 R2 [desktop apps only]
Target Platform Windows
Header winbase.h (include Windows.h)
Library Kernel32.lib
DLL Kernel32.dll
API set api-ms-win-core-ums-l1-1-0 (introduced in Windows 7)

See also

CreateUmsCompletionList

DequeueUmsCompletionListItems

Wait Functions