HumperHard Posted March 5, 2009 Posted March 5, 2009 Why is it closing with out hitting the Finish button? expandcollapse popup#include <Array.au3> #include <File.au3> #include <GuiConstantsEx.au3> #include <Misc.au3> #Include <GuiButton.au3> _Singleton("CreateUser") ; ######################################################################################### ; # Create GUI ; ######################################################################################### GUICreate("Account Creation", 300, 300) ; PROGRESS $progress = 0 ;$progressbar = GUICtrlCreateProgress(10, 10, 200, 20) $progressbar = GuiCtrlCreateProgress(60, 80, 150, 20) GuiCtrlSetData($progressbar, $progress) $label = GuiCtrlCreateLabel("Progress:", 5, 82) $userList = GUICtrlCreateList("", 176, 32, 121, 97) $finishedButton = GUICtrlCreateButton("Finished", 70,50,60) GuiSetState(@SW_SHOW) ; ######################################################################################### ; # GUI Event ; ######################################################################################### Opt("GUIOnEventMode",1) GUISetOnEvent ($GUI_EVENT_CLOSE, "Closed") GUISetOnEvent ($finishedButton, "Finished") Func Closed() Exit EndFunc Func Finished() MsgBox (4096, "test", "you clicked Finish") Exit EndFunc ; ######################################################################################### ; # Progress Bar ; ######################################################################################### $UserName = ("Tester") $Password = ("Password") $progress = $progress + 10 GuiCtrlSetData($progressbar, $progress)
Developers Jos Posted March 5, 2009 Developers Posted March 5, 2009 Where are you making sure that the program keeps running? Looks to me it ends after having executed the last line. Jos SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
HumperHard Posted March 5, 2009 Author Posted March 5, 2009 Where are you making sure that the program keeps running?Looks to me it ends after having executed the last line.JosHow do I keep it running?
Developers Jos Posted March 5, 2009 Developers Posted March 5, 2009 (edited) c'mon Just check the zillion examples While 1 sleep(50) Wend Edited March 5, 2009 by Jos SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
HumperHard Posted March 5, 2009 Author Posted March 5, 2009 c'mon Just check the zillion examples While 1 sleep(50) Wend Hey Im slowly learning.... Thanks
Bert Posted March 5, 2009 Posted March 5, 2009 Take AutoIt 1 2 3 The Vollatran project My blog: http://www.vollysinterestingshit.com/
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now