如题!
能获取当前正在使用的输入法也行!
搞定 贴上答案!! 改标题1
00000804 = 英文
e0040804 = 智能ABC 5.0
e0010804 = 全拼
E00E0804 = 微软拼音3.0
Opt("WinTitleMatchMode", 4)
Run("notepad.exe")
Sleep(500)
$hWnd = WinGetHandle("classname=Notepad")
MsgBox (0, "New Layout", _GetKeyboardLayout($hWnd))
Func _GetKeyboardLayout($hWnd)
Local $ret = DllCall("user32.dll", "long", "GetWindowThreadProcessId", "hwnd", $hWnd, "ptr", 0)
$ret = DllCall("user32.dll", "long", "GetKeyboardLayout", "long", $ret[0])
Return "0000"&Hex($ret[0], 4)
EndFunc
[ 本帖最后由 qop1830 于 2008-7-14 23:37 编辑 ] |