Jump to content
Sign in to follow this  

GUI run case on pressing enter

Recommended Posts


is there a way to press enter and run the case like this i tink:

Func TesT()
    Local $GUI, $msg, $Button
    $GUI = GUICreate("TesT", 495, 250)
    $Button = GuiCtrlCreateButton("Ok", 10, 10, 27, 20)
    While 1
        $msg = GUIGetMsg($GUI)
            Case $msg = $Button or {Enter}
                MsgBox(64,"TesT", "You pressed Ok")
Edited by Merchants

Share this post

Link to post
Share on other sites

Sure, have a look at styles or exstyles for the button creation function. IIRC, it has one for default button. :mellow:

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  


Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.