Newsgroups : Borland : borland.public.delphi.internet.winsock : 2006 Apr : Re: How to check if there's a internet connection?
| Subject: | Re: How to check if there's a internet connection? |
| Posted by: | "Martin James" (mjames_falc..@dial.pipex.com) |
| Date: | Sun, 23 Apr 2006 15:47:49 |
"Nick" <nick@hotmail.com> wrote in message
news:444b8d28$1@newsgroups.borland.com...
>
> This question has probably been asked before, but is there a way to check
if a computer is connected to the internet? Some of the answers that i've
found on the net are based on a out dated windows function, it just does not
work on Winxp. Surely there must be someway to find out if there's a
connection or not(through Delphi app), because the Winxp system detects a
internet connection and indicates it's presense with a computer icon in the
task bar. That shows that there is some way to check this, right?
Well, if 'the internet' was a single entity, it should be possible to
determine with certainty that a 'connection' exists. Since the internet is
a dynamically-changing network of interconnected nodes, defining an
'internet connection' is 'difficult'. For example, if the backbone router
at your ISP crashes, you can still 'connect' to the ISP and get the little
computer icon to appear on the taskbar, but you cannot reach your favourite
web sites. Are you 'connected to the internet', or not?
Most apps avoid this issue by attempting to connect to whatever server they
need to. If the connection fails, they issue a 'server unreachable'
messageBox, or similar. This box could give advice, eg 'Check your network
connections'.
It is very difficult to give explicit advice to users that is any more
detailed than this.
Rgds,
Martin
none