手缺一指 发表于 2008-11-1 00:01:27

怎么判断是否按了回车键?

怎么判断是否按了回车键?

bing614 发表于 2008-11-1 00:28:20

#include <Misc.au3>

$dll = DllOpen("user32.dll")

While 1
        Sleep ( 250 )
        If _IsPressed("0D                ", $dll) Then
                MsgBox(0,"_IsPressed", "End Key Pressed")
                ExitLoop
        EndIf
WEnd
DllClose($dll)

手缺一指 发表于 2008-11-1 01:26:47

看不懂,能说明一下吗?

gs008970 发表于 2008-11-1 02:11:43

这样判断好像不行吧?

sanhen 发表于 2008-11-2 00:15:27


HotKeySet( "{ENTER}", "Something" )

Func Something()
        MsgBox(64,"Test","您已经按下的回车键")
EndFunc

While 1
       
        Sleep(250)
       
WEnd

jtzxgfy 发表于 2008-11-10 20:47:44

原帖由 sanhen 于 2008-11-2 00:15 发表 http://www.autoitx.com/images/common/back.gif

HotKeySet( "{ENTER}", "Something" )

Func Something()
        MsgBox(64,"Test","您已经按下的回车键")
EndFunc

While 1
       
        Sleep(250)
       
WEnd


谢谢,学习了,收藏

rho123 发表于 2008-11-12 00:12:26

哈哈,老将出马,一个顶两

jiangzhanye 发表于 2008-11-12 00:25:34

#include <Misc.au3>
While 1
sleep(50)
      If _IsPressed("0D") Then
MsgBox(0,0,"按下回车键")


      EndIf
WEnd
页: [1]
查看完整版本: 怎么判断是否按了回车键?