Jump to content

Foolproof Internet Detection


Guest rathore
 Share

Recommended Posts

Guest rathore

is there any foolproof way of knowing if the pc is connected to internet?... something that'd work both if i've dialup & if i've broadband access (like a LAN whose server connects to internet), one that works with static ip & variating one alike!

Link to comment
Share on other sites

You can use ping... but it does not work with proxies.

You can use URLDownloadToFile function but it does not work always.

Maybe you can find some other unperfect ways, the best is nest them and check the result one by one.

Like you use ping (the easiest) if the result is Online you are done.

Else

you use UrlDownloadToFile if it is a success you are done

Else

Try to send a email to a fake address using blat or any other command line sender... if the email start you are done.

Else

so go on...

Edited by ezzetabi
Link to comment
Share on other sites

Guest rathore

makes some stupid sort of sense... :whistle:

i used to use a cmd line ftp upload tool for the purpose... much the same!

but i wanted to know AU3-script-only method...

i'll wait if somebody can suggest something else.

Link to comment
Share on other sites

Guest rathore

plz don't misunderstand... i just meant that its a bit stupendously long method... but if that's the only way then okay!

Link to comment
Share on other sites

The problem is, foolproof and anything PC related are not compatible. Even the most sure-thing isn't fully fool-proof because there are just so many variables that can't be controlled.

Why care if it's some long method, though? Just write a function and #include it when you need it...?

Link to comment
Share on other sites

Guest rathore

yeah maybe u're right valik... especially coz i've read a related post by u & others discussing this topic in (i reckon) idea lab.

Link to comment
Share on other sites

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
 Share

  • Recently Browsing   0 members

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