Caer12 Posted August 9, 2007 Share Posted August 9, 2007 When I right click the au3 file and choose run script, it works perfectly and does everything I want it to do.When I right click the file and click compile with options, I just click compile after the window comes up and this is what I get when I run the exe.Here's a file with the images and source.http://www.zerowaitingtime.com/25825-download-QSS.rarHere is the source, I need help finding out what I need to do or what I'm doing wrong so that I can have it show the number of players. Also if someone could give me an example of how to do the fileinstall() function for the images so that i don't need them in the folder, I've seen the help file on file install but I just have so problems with the directories, I just basically don't know where they need to go.Any help is greatly appreciated.expandcollapse popup#include <GUIConstants.au3> #include <INet.au3> #include <String.au3> #include <array.au3> ;GUI GUICreate("Qonquer Server Status", 301, 109) GUICtrlSetBkColor(-1, 000000) Opt("GUICoordMode", 2) AdlibEnable("SetPlayers", 5000) ;SERVER STATUS $widthCell = 36 GUICtrlSetColor(-1, 0xff00) ;SEARCH FOR TEXT AND POSTS CASE Dim $avCodes[1] = ["GIF89"] $src1 = _INetGetSource('http://www.qonquer.com/status/status.php?link=127.0.0.1:9958') $trm1 = StringTrimLeft($src1, 0) $trm3 = StringTrimRight($trm1, 49) For $i = 0 To UBound($avCodes) - 1 $Input = $avCodes[$i] $Pos = _ArraySearch($trm3, $Input) Select Case $Pos = -1 GUICtrlCreatePic("online.bmp", 12, 38, 36, 18) Case Else GUICtrlCreatePic("offline.bmp", -1, 0, 36, 18) EndSelect Next ;PLAYERS ONLINE $label = GUICtrlCreateLabel(Getplayers(), -1, 33, $widthCell) GUISetState() ;BACKGROUND IMAGE $background = GUICtrlCreatePic("qbackground.bmp", -47, -105, 304, 109) While 1 $msg = GUIGetMsg() If $msg = $GUI_EVENT_CLOSE Then ExitLoop WEnd Func Getplayers() $src = _INetGetSource('http://69.41.179.98:9980/online.js') $trm = StringTrimLeft($src, 17) $trm2 = StringTrimRight($trm, 4) Return $trm2 EndFunc ;==>Getplayers Func SetPlayers () GUICtrlSetData($label, Getplayers()) EndFunc ;==>SetPlayers Link to comment Share on other sites More sharing options...
Achilles Posted August 9, 2007 Share Posted August 9, 2007 (edited) I haven't looked at this but it might be a problem with beta. Maybe you are running beta but not compiling with it... not sure, just an idea. FileInstall loads the files into the .exe when the script is compiled (or so I've been led to believe). So, you put something like this: FileInstall(the exact path of the file, where it will be extracted when the application is run) Now the files are in the .exe and when you run the .exe, when it finds the FileInstall line, it will place that file where it's supposed to go (based on the second parameter)... Hope that made sense, let me know if it didn't! Edited August 9, 2007 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...
gamerman2360 Posted August 9, 2007 Share Posted August 9, 2007 They seem to do the same thing whether it is compiled or not. It displays the number then when it trys to set the data is just goes blank. I bet it is because you are using several controls that are overlapping eachother. (Not sure how to fix it) FileInstall(), when not compiled, acts just like FileCopy(). When the script is compiled, it's the same except there is no source.. When the script is compiled the files that are in the source are included in the .exe. Link to comment Share on other sites More sharing options...
Caer12 Posted August 9, 2007 Author Share Posted August 9, 2007 Thank you both for better explaining the fileinstall function, now I just need to find out the problem with compiling, gif had given me a script that would place the number of players online in a message box, when I compiled it it did the same thing. When I posted about it doing that in another topic, gif said that it was working for him. I'll try a few different things tomorrow and see if I can't work it out, thanks again for your help. Link to comment Share on other sites More sharing options...
gamerman2360 Posted August 9, 2007 Share Posted August 9, 2007 Fixed it.. I hate using the cordinate mode you used so it was hard to move things around.. But it turns out I didn't need to. I found a tiny thing in the help file that allowed you to set the z-order of a control. $GUI_ONTOP sets a control to be on the bottom when used with GUICtrlSetState() : \... All that means is that after you add the background picture you need to do a: GUICtrlSetState(-1, $GUI_ONTOP) $background = GUICtrlCreatePic("qbackground.bmp", -47, -105, 304, 109) GUICtrlSetState(-1, $GUI_ONTOP)v3.2.4.9 Link to comment Share on other sites More sharing options...
Caer12 Posted August 9, 2007 Author Share Posted August 9, 2007 Thank you, I was having problems with that earlier so that makes it easier. If someone could possibly try and compile the script themselves and see if they can see the number of players and if so, upload the exe to a file host and place the link in here so I can see if it is just my computer. 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