File Management Functions


PostQueuedCompletionStatus Function

Posts an I/O completion packet to an I/O completion port.

Syntax

C++
BOOL WINAPI PostQueuedCompletionStatus(
  __in      HANDLE CompletionPort,
  __in      DWORD dwNumberOfBytesTransferred,
  __in      ULONG_PTR dwCompletionKey,
  __in_opt  LPOVERLAPPED lpOverlapped
);

Parameters

CompletionPort [in]

A handle to an I/O completion port to which the I/O completion packet is to be posted.

dwNumberOfBytesTransferred [in]

The value to be returned through the lpNumberOfBytesTransferred parameter of the GetQueuedCompletionStatus function.

dwCompletionKey [in]

The value to be returned through the lpCompletionKey parameter of the GetQueuedCompletionStatus function.

lpOverlapped [in, optional]

The value to be returned through the lpOverlapped parameter of the GetQueuedCompletionStatus function.

Return Value

If the function succeeds, the return value is nonzero.

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

Remarks

The I/O completion packet will satisfy an outstanding call to the GetQueuedCompletionStatus function. This function returns with the three values passed as the second, third, and fourth parameters of the call to PostQueuedCompletionStatus. The system does not use or validate these values. In particular, the lpOverlapped parameter need not point to an OVERLAPPED structure.

Requirements

Minimum supported clientWindows 2000 Professional
Minimum supported serverWindows 2000 Server
HeaderWinBase.h (include Windows.h)
LibraryKernel32.lib
DLLKernel32.dll

See Also

CreateIoCompletionPort
File Management Functions
GetQueuedCompletionStatus
OVERLAPPED

Send comments about this topic to Microsoft

Build date: 11/12/2009

Tags :


Page view tracker