This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Beginning Java and the fly likes Java application Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Java application" Watch "Java application" New topic

Java application

tom picot

Joined: Feb 05, 2002
Posts: 1
Hi all,
I am developing a java stand-alone application and it is required to constantly check whether the application/client machine is connected to the internet. What is the best way to do this from within the application programmatically?
Thanks in advance.
Dave Vick
Ranch Hand

Joined: May 10, 2001
Posts: 3244
You could create a new Thread the occasionally wakes up and pings the machine it is checking.
The actual implementation of that is alittle beyond me at this point but I'm sure someone else here can give you a quick example.
hope that helps a little bit...

I agree. Here's the link:
subject: Java application
Similar Threads
main method
Session Time out
Print pdf file without opening.
Getting database connection failed
Not serializable Exception or No Data to read from socket