Archive: problem with detecting active internet connection


problem with detecting active internet connection
Hello,

I had a problem during the detection of active internet connection. I am using the plugin dialer:attemptconnect to check whether user system has a active internet connection. But while checking its also taking local host (127.0.0.1) as an active internet connection and need to rectify that problem. Can you please help me out as how to check for active internet (wireless or LAN)for the given installer??

Thanks alot.

Veeru


The best method is to simulate a real usage. If you're going to download something big, download something small first to test; if you're about to perform a lot of RPC queries, try a simple one first; etc. You could also go for the famous Google ping. Any other method is bound to fail on weird cases such as LAN with non-LAN IP addresses.


Could you please give me an idea as how to ping google using NSIS scripts?

Thanks alot.


nsExec::Exec "ping -n 1 www.google.com"
Pop $0 # $0 is zero if ping was successful

Thanks alot for your help.