还是不行啊,在线等,赐教啊
我是这样的
#include <ButtonConstants.au3>
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
Opt("GUIOnEventMode", 1) ; 切换为 OnEvent 模式
#Region ### START Koda GUI section ### Form=
$Form1 = GUICreate("Form1", 633, 454, 193, 115)
$Input1 = GUICtrlCreateInput("", 176, 120, 121, 21)
$Button1 = GUICtrlCreateButton("Button1", 200, 224, 75, 25, 0)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###
GUISetOnEvent($GUI_EVENT_CLOSE, "_Exit")
GUICtrlSetOnEvent($Button1, "_Exit");
While 1
$dll = DllOpen("___MFCOM.DLL")
$x = DllCall($dll, "hwnd", "ComInit", "int", 3)
$y = DllCall($dll, "ptr", "TxRxRW", "hwnd", $x)
If $y <> "" Then
GUICtrlSetData($Input1, $y)
EndIf
DllCall($dll,"int","ComExit","hwnd",$x)
Sleep(1000)
WEnd
Func _Exit()
Exit
EndFunc ;==>_Exit
|