IVsIME.GetImmContext Method

Retrieves the Input Method Editor (IME) context for a given window. Use before getting or setting IME information using methods such as GetImmCompositionString.

Namespace:  Microsoft.VisualStudio.Shell.Interop
Assembly:  Microsoft.VisualStudio.Shell.Interop (in Microsoft.VisualStudio.Shell.Interop.dll)


Function GetImmContext ( _
    hwnd As IntPtr, _
    <OutAttribute> ByRef phimc As UInteger _
) As Integer
‘사용 방법
Dim instance As IVsIME
Dim hwnd As IntPtr
Dim phimc As UInteger
Dim returnValue As Integer

returnValue = instance.GetImmContext(hwnd, _
int GetImmContext(
    IntPtr hwnd,
    out uint phimc
int GetImmContext(
    [InAttribute] IntPtr hwnd, 
    [OutAttribute] unsigned int% phimc
abstract GetImmContext : 
        hwnd:IntPtr * 
        phimc:uint32 byref -> int 
function GetImmContext(
    hwnd : IntPtr, 
    phimc : uint
) : int


  • phimc
    Type: System.UInt32%
    [out] Pointer to a handle to the IME context.

Return Value

Type: System.Int32
If the method succeeds, it returns S_OK. If it fails, it returns an error code.


COM Signature

From vsshell.idl:

HRESULT IVsIME::GetImmContext(
   [in] HWND hwnd, 
   [out] HIMC * phimc

.NET Framework Security

See Also


IVsIME Interface

IVsIME Members

Microsoft.VisualStudio.Shell.Interop Namespace