lm1 Posted November 2, 2006 Share Posted November 2, 2006 hey everyone i am just starting with autoit it comes with my new job at an internet cafe, we are making a script to launch battlefield 2142, with one it launches our licensing program that allows our customers to use one of our house accounts and the other that runs just battlefield 2142. it launches a gui that lets you choose one of the two scripts. since i am very new to this scripting dont be to harsh if i really botched this GuiCreate("Battlefield 2142", 350, 125,(@DesktopWidth-380)/2, (@DesktopHeight-400)/2 , $WS_OVERLAPPEDWINDOW + $WS_VISIBLE + $WS_CLIPSIBLINGS) $radio1 = GUICtrlCreateRadio ("Liquid Matrix Account", 10, 10, 150, 20 ) GUICtrlSetState ($radio1,$GUI_CHECKED) $radio2 = GUICtrlCreateRadio ("Personal Account (must have purchased game)", 10, 40, 350, 20) $Button_1 = GuiCtrlCreateButton("ok", 125, 75, 90, 30) GUISetState(); Command respondsible for setting Gui in a visible or usable state. Very important ; Run the GUI until the dialog is closed While 1 $msg = GUIGetMsg() Select Case $msg = $GUI_EVENT_CLOSE $answer1=MsgBox(4, "Warning", "Close without addons loaded?") If $answer1 = 6 Then Exit EndIf Case $msg = $Button_1 $answer2 = MsgBox(4, "Notice", "Start 2142?") if $answer2 = 7 then ContinueLoop If $answer2 = 6 Then IF GUICtrlRead ($radio1) = $GUI_CHECKED Then Run ("BF2142LM.exe","z:\batch\autoit") EndIf If GUICtrlRead ($radio2) = $GUI_CHECKED Then Run("BF2142LMPersonal.exe", "z:\batch\autoit") EndIf EndIf ExitLoop EndSelect WEnd Any help would be very helpful Link to comment Share on other sites More sharing options...
Achilles Posted November 2, 2006 Share Posted November 2, 2006 (edited) Any help would be very helpfulYou could use an #include <Autoit.au3> file instead of the run... That is if both your other files are autoit also...But if that doesn't work, I'm not really sure what you want... The run command should be working if you got the directory correct.EDIT: Put 'run' instead of 'fun'... Edited November 2, 2006 by Piano_Man My Programs[list][*]Knight Media Player[*]Multiple Desktops[*]Daily Comics[*]Journal[/list] 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