GetKeyboardStatus (Compact 2013)

3/28/2014

This function returns the status of the hardware keyboard.

Syntax

DWORD GetKeyboardStatus();

Parameters

None.

Return Value

This function returns a bit mask indicating whether or not a keyboard is present and what its capabilities are. The following table shows the bit mask.

Identifier

Value

Description

KBDI_KEYBOARD_PRESENT

0x0001

Indicates whether or not the system has keyboard hardware.

KBDI_KEYBOARD_ENABLED

0x0002

Indicates whether or not the keyboard hardware is enabled.

This bit is assumed to be set but can be modified with EnableHardwareKeyboard.

KBDI_KEYBOARD_ENTER_ESC

0x0004

Indicates whether or not the keyboard hardware has ENTER and ESC keys.

KBDI_KEYBOARD_ALPHA_NUM

0x0008

Indicates whether or not the keyboard hardware has alphanumeric keys.

Requirements

Header

winuser.h

Library

Kbdui.lib

See Also

Reference

Keyboard Functions
EnableHardwareKeyboard

Other Resources

Keyboard and Mouse Driver Registry Settings