Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Can I truly check for Internet connection?
Message
From
07/01/2003 12:19:20
 
General information
Forum:
Visual FoxPro
Category:
Internet applications
Miscellaneous
Thread ID:
00724735
Message ID:
00738871
Views:
26
Hello Mel,

It would do the check, but I don't think it would prompt to dial if not connected. In that same thread, Rodd went the wwIPStuff route, because apparently it will dial if necessary.

Re: Can I truly check for Internet connection? Thread #724735 Message #725157

>Hi Steve,
>
>You posted the following a few weeks ago - would it also check if the user is hooked to the web with a DialUp connection?
>
>Mel Cummings
>
>
>>For a user with a LAN connection to the internet, pinging is the most reliable method. If you are concerned that an internet server may be down, then check a different server if the first one returns false.
>
>Here is a function you can use
>
>
>function checkInternetConnection
>lparameters lcWebAddress
>
>	Declare Integer InternetCheckConnection in Wininet.dll String Url, Long dwFlags, Long Reserved
>
>	If InternetCheckConnection(lcWebAddress, 1, 0) != 0
>		return .t.
>	Else
>		return .f.
>	EndIf
>endproc
>
>Example usage:
>
>
>? checkInternetConnection("http://www.microsoft.com")<
Steve Gibson
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform