Jammer Posted February 21, 2005 Share Posted February 21, 2005 Ok first the code: Case $msg = $run If GUICtrlRead($list_1) = "" Then MsgBox(64, "You have 10 seconds", "Select a server or die! In 10 seconds!") sleep(10000) EndIf $z = 0 Do $z = $z + 1 Until GUICtrlRead($list_1) = IniRead("server.ini", "SN", "key" & $z, "") $conip = IniRead("server.ini", "SIP", "key" & $z, "") $ofile = FileOpen("realmlist.wtf", 2) FileWrite($ofile, "set realmlist " & $conip) FileClose($ofile) ;Run with options $comline = "" if GUICtrlRead ($c1) = 1 Then $comline = $comline & " -windowed" if GUICtrlRead ($c2) = 1 Then $comline = $comline & " -opengl" if GUICtrlRead ($c3) = 1 Then $comline = $comline & " -nosound" MsgBox(64, "Stats", $comline) So as you can see in the second line it checks if anything is selected in the list and I don't know how to make it do nonething if nonething is selected in the list and do the code that is below if there is something selected in the select list.....As you can see I made currently a timer... If nonething is selected he has 10 seconds )). So if nonething is selected that it would do nonething and just pop up a msgbox(64, "Error", "Please select a server") Link to comment Share on other sites More sharing options...
SlimShady Posted February 21, 2005 Share Posted February 21, 2005 (edited) Case $msg = $run MsgBox(64, "You have 10 seconds", "Select a server or die! In 10 seconds!") sleep(10000) If GUICtrlRead($list_1) = "" Then msgbox(64, "Error", "Please select a server") ContinueLoop EndIf $z = 0 Do $z = $z + 1 Until GUICtrlRead($list_1) = IniRead("server.ini", "SN", "key" & $z, "") $conip = IniRead("server.ini", "SIP", "key" & $z, "") $ofile = FileOpen("realmlist.wtf", 2) FileWrite($ofile, "set realmlist " & $conip) FileClose($ofile) ;Run with options $comline = "" if GUICtrlRead ($c1) = 1 Then $comline = $comline & " -windowed" if GUICtrlRead ($c2) = 1 Then $comline = $comline & " -opengl" if GUICtrlRead ($c3) = 1 Then $comline = $comline & " -nosound" MsgBox(64, "Stats", $comline) Edited February 21, 2005 by SlimShady Link to comment Share on other sites More sharing options...
Jammer Posted February 21, 2005 Author Share Posted February 21, 2005 (edited) But it will keep the msg poping... i need it to pop once and then the user has to select a server and press $run again.... if the server is not selected it should popup again... and the user will have to select server and press run... again... and so and so and so... And the sleep and Select a server or die is not needed ... i Edited so.. : Case $msg = $run While GUICtrlRead($list_1) = "" MsgBox(64, "Error", "Please select a server") WEnd $z = 0 Do $z = $z + 1................................................ but it keeps the window popin... i need it to pop once and then user has to select a server and press run again.. as I sayd before.... if he presses run and the server is not selected... it has to pop up once again and then the user has to select a server and press run again... i hope u understand my messed mind... Edited February 21, 2005 by Jammer 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