Compartilhar via


ImmGetVirtualKey

A version of this page is also available for

Windows Embedded CE 6.0 R3

4/8/2010

This function recovers the original virtual key value associated with a key input message processed by the IME.

Syntax

UINT ImmGetVirtualKey( 
  HWND hWnd
);

Parameters

  • hWnd
    [in] Handle to the window that receives the key message.

Return Value

If TranslateMessage is called by the application, ImmGetVirtualKey returns VK_PROCESSKEY; otherwise, it returns the virtual key.

Remarks

Although the IMM sets the virtual key value to VK_PROCESSKEY when the IME processes a given virtual key, an application can recover the original virtual key value with the ImmGetVirtualKey function. This function is only used for key input messages containing the VK_PROCESSKEY value. Applications can only get the original virtual key by using this function after receiving the WM_KEYDOWN (VK_PROCESSKEY) message, and before TranslateMessage is called in its own message loop.

Requirements

Header imm.h
Library Coreimm.lib
Windows Embedded CE Windows CE .NET 4.0 and later
Windows Mobile Windows Mobile Version 5.0 and later

See Also

Other Resources

Input Method Manager (IMM) Functions