找了一下别人的代码
#cs ----------------------------------------------------------------------------
AutoIt Version: 3.2.10.0
Author: Bj鰎n Kaiser
Script Function:
#ce ----------------------------------------------------------------------------
Opt("MustDeclareVars", 1)
#include <gimagex_com.au3>
Dim $iRC, $oWIM, $oEvent
;$oWIM = _gimagex_object()
$oWIM = ObjCreate("GImageX.GImageXCtrl")
$oEvent = ObjEvent($oWIM, "objWIM_")
ProgressOn("ImageX", "Please wait ...")
$iRC = _gimagex_capture($oWIM, "I:\", "D:\xp.wim", "test")
ConsoleWrite("RC:" & @TAB & $iRC & @CRLF & "@error:" & @TAB & @error & @CRLF)
$oEvent = 0
$oWIM = 0
ProgressOff()
Func objWIM_Progress($iPercent, $iSeconds)
ProgressSet($iPercent, "ETA: " & $iSeconds & " seconds")
ConsoleWrite("ETA:" & @TAB & @TAB & $iSeconds & @CRLF & "Progress:" & @TAB & $iPercent & @CRLF)
EndFunc ;==>ImageXEvent_Progress
最后发现,运行结果跟我的一样,还是无法获取进度。我现在开始怀疑是不是DLL版本问题或者是编译器3.3有问题。 |