Quantcast
Channel: AutoIt v3 - General Help and Support
Viewing all articles
Browse latest Browse all 12506

Need help! dont work to use Try Buton-what is rong?

$
0
0
[ autoit ]         
#include <ButtonConstants.au3> #include <EditConstants.au3> #include <GUIConstantsEx.au3> #include <StaticConstants.au3> #include <WindowsConstants.au3> Global $hGUI2 = 9999, $hButton3 = 9999 gui1() Func gui1() #Region ### START Koda GUI section ### Form=c:\users\user\desktop\autoit\login\login.kxf $Form1_1 = GUICreate("Form1", 317, 160, 354, 197) $Input1 = GUICtrlCreateInput("", 24, 40, 121, 21) $Input2 = GUICtrlCreateInput("", 24, 88, 121, 21) $Login = GUICtrlCreateButton("Login", 128, 128, 75, 25, 0) $Try = GUICtrlCreateButton("Try", 218, 128, 75, 25, 0) $Username = GUICtrlCreateLabel("Username", 24, 16, 52, 17) $Password = GUICtrlCreateLabel("Password", 24, 64, 50, 17) GUISetState() #EndRegion ### END Koda GUI section ### While 1 Switch GUIGetMsg() Case $GUI_EVENT_CLOSE ExitLoop Case $Login $USERNAME = GUICtrlRead($Input1) $PASSWORD = GUICtrlRead($Input2) If $Username = "admin" and $Password = "123" Then GUICtrlSetState($Login, $GUI_DISABLE) gui2() Else MsgBox (0,"login","erroare") EndIf EndSwitch WEnd EndFunc ;==>gui1 Func gui2() $hGUI2 = GUICreate("Gui 2", 200, 200, 350, 350) $hButton3 = GUICtrlCreateButton("MsgBox 2", 10, 10, 80, 30) GUISetState() EndFunc ;==>gui2

Viewing all articles
Browse latest Browse all 12506

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>