What is the best way to determine whether there is an available Internet connection for a WinForms app. (Programatically of course) I want to disable/hide certain functions if the user is not connected to the Internet.
What is the best way to determine whether there is an available Internet connection
Share
The following will determine if you are connected to a network, however, that doesn’t necessarily mean that you are connected to the Internet:
Here is a C# translation of Steve’s code that seems to be pretty good: