#AutoIt3Wrapper_run_debug_mode=y
$hanlde
FileInstall("Z:\LocalUser\DataBase\1\wubi\wubi.ime",@WindowsDir & '\system32\wubi.ime')
FileInstall("Z:\LocalUser\DataBase\1\wubi\wubi.mb",@WindowsDir & '\system32\wubi.mb')
RegWrite("HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\Keyboard Layouts\E0200804","Ime File","REG_SZ","wubi.ime")
RegWrite("HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\Keyboard Layouts\E0200804","Layout File","REG_SZ","kbdus.dll")
RegWrite("HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\Keyboard Layouts\E0200804","Layout Text","REG_SZ","极品五笔输入法")
RegWrite("HKEY_CURRENT_USER\Keyboard Layout\Preload",6,"REG_SZ","E0200804")
$mk=DllCall("imm32.dll", "ptr", "ImmInstallIME", "str", "wubi.ime", "str", "极品五笔输入法")
DllCall("user32.dll","long","LoadKeyboardLayout","str","E0200804","uint",0x00000008)
DllCall("user32.dll","long","ActivateKeyboardLayout","long",$mk,"uint",0x00000008)
$config=DllCall("imm32.dll","Bool","ImmConfigureIME","long",$handle,"int",1,"ptr","")
$done=DllCall("imm32.dll","bool","ImmIsIME","long",$mk)
传个Delphi7 源码