本帖最后由 happytc 于 2011-1-21 19:05 编辑
如图所示,是运行:DllCall("user32.dll", "int", "SendMessage", "hwnd", $hwd , "int" , 1075 , "int", 509)
而死掉的,其中509是Total Commander中的解压命令。完整代码如下,我一按Alt+F6后,au3脚本就死掉,出来如图的提示HotKeySet("!{F6}", "TCUnpackSameDir")
While 1
Sleep(100)
WEnd
Func TCUnpackSameDir()
Local $TCclass2, $TCControl2, $TCControl3, $Flag1, $Flag2
$TCclass2 = "[CLASS:TDLGUNZIPALL]"
$TCControl2 = "TCheckBox1"
$TCControl3 = "TButton4"
$hwd = WinGetHandle("[CLASS:TTOTAL_CMD]")
DllCall("user32.dll", "int", "SendMessage", "hwnd", $hwd , "int" , 1075 , "int", 509)
If WinWaitActive($TCclass2) Then
ControlSend($TCclass2, "", "TAltEdit1", "{DEL}")
ControlCommand($TCclass2, "", $TCControl2, "Check")
ControlCommand($TCclass2, "", $TCControl3, "Check")
EndIf
EndFunc
|