Hi,
I'm busy trying to write a script that creates a GUI where the user can select a bunch of programs to launch. That part's easy enough, although I also want the GUI to display a few other things. I've managed to get 2 more child GUIs to pop up with images using InetGet(), but I'm struggling with retrieving text from _IECreate(), and at the same time keeping the GUI active. My solution looks pretty inelegant to me, but I can't think of any better way to do it:
#include <IE.au3>
#include <String.au3>
$server1URL = "http://www.gametracker.com/server_info/113.212.96.249:16567/"
$curServer = ""
ragamuffin()
Func GUIloopy() ;This is where the GUI loop goes
While 1
If _IEPropertyGet($curServer, "busy") = False Then
ConsoleWrite("Done")
ExitLoop
EndIf
WEnd
EndFunc
_IEQuit($curServer)
Func ragamuffin()
$curServer = _IECreate($server1URL, 0, 0, 1)
Do
loopy()
Until _IEPropertyGet($curServer, "busy") = False
$curReadText = _IEBodyReadText($curServer)
$currentMapLame = _StringBetween($curReadText, "CURRENT MAP ", "Is")
$currentMap = $currentMapLame[0]
$currentMap = StringStripWS($currentMap,7)
MsgBox(0, "blah", $currentMap)
_IEQuit($curServer)
EndFunc
Now, this code works fine for me in my main script, but I can't help but notice that it gives me the error:
--> IE.au3 V2.4-0 Error from function _IEPropertyGet, $_IEStatus_InvalidDataType
Seemingly every time it loops the GUI.
Anyway, the script works just fine, I was just wondering if I should be concerned about the (orange) error, or just ignore it?
Also, is that a stupid way of keeping the GUI 'active'? Is there a better way I could do it?