Jump to content

Recommended Posts

Posted

i am currently forced to use a mobile broadband stick for my internet, which works ok but drops out now and then.

i want to write a script to first check if it is connected, then connect if it has stopped. there is a connect automatically option but this

only seems to work when pc first starts and doesnt reconnect if disconnected. i tried plying with the tcp startup and look commands using the ip address, but amongst other things i noticed each time dongle logs iy has a different ip or there is a real chance im just doing it wrong. any one have any ideas?

  • Moderators
Posted

Hi, Kryptar. Actually restarting the Air Card really depends on the Service Provider, as well as the model of hardware. As it sounds as though you want this script to run in the SysTray and monitor, have you attempted to use a ping loop? Something like this might be a start:

While 1
Ping("www.google.com")
  If @error Then
   ;Code to restart the Air Card service or application.
  EndIf
Sleep(30000) ;<--pause for 30 seconds.
WEnd

"Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball

How to get your question answered on this forum!

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...