Get Internet Connection State
By
Jamie on
Jan 1st, 2012 9:03 am I've developed a code that is intended to be used in an application extension (as with all my codes) that will tell you if the current computer has an internet connection.
To use just include the namespace given at the top of the snippet, then the connection state is a variable of custom type ConnectionState. Usage is for whatever you wish to use it for. If you're using it to display the connection state of the current computer to the user via string (label, textbox, button text, console application) just apply the .ToString() method to the end as with any other variable. It will simply print Connected or Disconnected.
I've upgraded this and will be re-posting it.
lxXTaCoXxl
Posting Whiz
311 posts since Mar 2011
Reputation Points: 21
Solved Threads: 18
Skill Endorsements: 2
© 2013 DaniWeb® LLC
Page generated in 0.0607 seconds
using 2.69MB