Qslig Posted January 30, 2005 Share Posted January 30, 2005 Help Okey, Where it says If $msg = $run Then $answer1 = Inputbox("run", "Type in what you want to run") I want to countinue on that like run($answer1) but I dont know hot to do that. Like when you have enter the answer in Inputbox then it will be $answer1 and right after you have typed in your answer and hit OK then I want it to run the answer run($answer1) ;Start GUI #include <GUIConstants.au3> GUICreate("Supr Progr") GUISetState () ;Meny 1 $arkiv = GUICtrlCreateMenu ("Arkiv") $run = GUICtrlCreateMenuitem ("kör",$arkiv) $Stang = GUICtrlCreateMenuitem ("Stäng",$arkiv) ;Meny2 $help = GUICtrlCreateMenu ("?") $info = GUICtrlCreateMenuitem ("Info",$help) ; Håller igång programet tills man stänger det While 1 $msg = GUIGetMsg() If $msg = $run Then $answer1 = Inputbox("run", "Type in what you want to run") If $msg = $info Then msgbox(0, "Info", "Fett med info här") If $msg = $GUI_EVENT_CLOSE or $msg = $stang Then ExitLoop Wend Link to comment Share on other sites More sharing options...
CyberSlug Posted January 30, 2005 Share Posted January 30, 2005 (edited) Replace the line If $msg = $run Then $answer1 = Inputbox("run", "Type in what you want to run")with the following:If $msg = $run Then $answer1 = Inputbox("run", "Type in what you want to run") ;might want to do error checking here; ;might also want to say Opt("RunErrorsFatal", 0) ???? or check if fileExists Run($answer1) EndIf Edited January 30, 2005 by CyberSlug Use Mozilla | Take a look at My Disorganized AutoIt stuff | Very very old: AutoBuilder 11 Jan 2005 prototype I need to update my sig! Link to comment Share on other sites More sharing options...
Qslig Posted January 30, 2005 Author Share Posted January 30, 2005 CyberSlug thx allot, that going to help allot in the future! Link to comment Share on other sites More sharing options...
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