realkiller Posted July 18, 2006 Share Posted July 18, 2006 hi i made a script for my router that it enables internet because my isp is nog that good, the only problem is that it always execute the commands to re enable internet even when i got internet can somone help me plz:D #NoTrayIcon While 1 $acces = "Verbinding maken met 192.168.1.1" $status = "Status - Microsoft Internet Explorer" If Ping("http://www.google.nl") Then Sleep("100") Else Run(@ProgramFilesDir&"\Internet Explorer\iexplore.exe http://192.168.1.1/Status_Router.asp") WinWaitActive($acces) ControlSend($acces, "", "Edit2", "admin") ControlSend($acces, "", "Edit3", "telenet") ControlClick($acces, "", "Button2") WinWaitActive($status) WinSetState($status, "", @SW_MAXIMIZE) EndIf If StatusbarGetText($status, "Gereed")Then MouseClick("left", 469, 757, 100) Else Sleep("100") EndIf Sleep("600000") WEnd Remote 3.1 BetaRemote Media Player ControlUSB Security 1.2 Link to comment Share on other sites More sharing options...
Richard Robertson Posted July 18, 2006 Share Posted July 18, 2006 What do you mean? The router and ISP should not directly be related unless you got the router with your connection. Don't use the whole address. Use Ping("google.nl"). Ping communicates with computers, not websites. Http is a protocol. Link to comment Share on other sites More sharing options...
Xenobiologist Posted July 18, 2006 Share Posted July 18, 2006 (edited) HI, does this help? #NoTrayIcon $acces = "Verbinding maken met 192.168.1.1" $status = "Status - Microsoft Internet Explorer" While 1 Sleep(10000) check() WEnd Func check() If Ping("www.google.nl") <> 0 Or @error <> 0 Then Run(@ProgramFilesDir & "\Internet Explorer\iexplore.exe http://192.168.1.1/Status_Router.asp") WinWaitActive($acces) ControlSend($acces, "", "Edit2", "admin") ControlSend($acces, "", "Edit3", "telenet") ControlClick($acces, "", "Button2") WinWaitActive($status) WinSetState($status, "", @SW_MAXIMIZE) EndIf If StatusbarGetText($status, "Gereed") Then MouseClick("left", 469, 757, 100) Else Sleep(100) EndIf EndFunc ;==>check So long, Mega Edited July 18, 2006 by th.meger Scripts & functions Organize Includes Let Scite organize the include files Yahtzee The game "Yahtzee" (Kniffel, DiceLion) LoginWrapper Secure scripts by adding a query (authentication) _RunOnlyOnThis UDF Make sure that a script can only be executed on ... (Windows / HD / ...) Internet-Café Server/Client Application Open CD, Start Browser, Lock remote client, etc. MultipleFuncsWithOneHotkey Start different funcs by hitting one hotkey different times Link to comment Share on other sites More sharing options...
realkiller Posted July 18, 2006 Author Share Posted July 18, 2006 thx all for fast replying iam going to test it @home;) Remote 3.1 BetaRemote Media Player ControlUSB Security 1.2 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