Partager via


CreateAsyncIoHandle (Compact 2013)

3/26/2014

This function is used by a device driver to change XXX_Read (Device Manager), XXX_Write (Device Manager), and XXX_IOControl (Device Manager) function calls into asynchronous I/O.

Syntax

HANDLE CreateAsyncIoHandle(
  HANDLE hIoRef,
  LPVOID* lpInBuf,
  LPVOID* lpOutBuf
);

Parameters

  • hIoRef
    [in] Asynchronous I/O reference handle. This handle is passed in as the last parameter of the XXX_Read, XXX_Write, and XXX_IoControl functions.
  • lpInBuf
    [out] Address of the asynchronous input buffer.
  • lpOutBuf
    [out] Address of the asynchronous output buffer.

Return Value

Returns a handle that is used as the parameter to the SetIoProgress and CompleteAsyncIo functions, if successful. If the function is not successful it returns NULL. To obtain extended error information, call GetLastError.

Remarks

After the call to CreateAsyncIoHandle succeeds, the caller must use the input buffer and output buffer addresses that are returned from this call. The data and address of the original pointers passed in from the caller might be invalid.

Requirements

Header

pkfuncs.h

See Also

Reference

Device Manager Functions