Applications that read character input from the keyboard need to use the TranslateMessage function in their message loops. TranslateMessage translates a keyboard-input message into a corresponding ANSI-character message, WM_CHAR or WM_SYSCHAR. These messages contain the ANSI character codes for the given key in the wParam parameter. The lParam parameter is identical to lParam in the keyboard-input message.