Share via


IOCTL_CONSOLE_GETMODE (Compact 2013)

3/28/2014

This I/O control message returns the modes associated with the console. Send this message with DeviceIoControl.

Syntax

BOOL DeviceIoControl(
    HANDLE hDevice,           // handle to device
    DWORD dwIoControlCode,    // use to IOCTL_CONSOLE_GETMODE
    LPVOID lpInBuffer,        // pointer to input buffer
    DWORD nInBufferSize,      // input buffer size
    LPVOID lpOutBuffer,       // pointer to output buffer
    DWORD nOutBufferSize,     // output buffer size
    LPDWORD lpBytesReturned,  // number of bytes returned
    OVERLAPPED lpOverlapped   // pointer to OVERLAPPED structure
);

Parameters

  • hDevice
    [in] Handle to the device.
  • dwIoControlCode
    [in] Control code for the operation. Use IOCTL_CONSOLE_GETMODE for this operation.
  • lpInBuffer
    [in] Set to NULL.
  • nInBufferSize
    [in] Set to zero.
  • lpOutBuffer
    [out] Not used; set to NULL.
  • nOutBufferSize
    [out] Not used; set to zero.
  • lpBytesReturned
    [out] Not used; set to NULL.
  • lpOverlapped
    [out] Not used; set to NULL.

Return Values

Returns TRUE if successful; otherwise, returns FALSE.

This function copies the mode values of the console to the PBYTE pBufOut. This value can be compared with CECONSOLE_MODE_ECHO_INPUT, CECONSOLE_MODE_LINE_INPUT or CECONSOLE_MODE_PROCESSED_OUTPUT to determine whether those values are set for the console. See Console Flags for more information.

Requirements

Header

console.h

See Also

Reference

Console IOCTLs

Other Resources

OAL IOCTLs