File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Java in General and the fly likes Java Networking 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 » Java in General
Bookmark "Java Networking" Watch "Java Networking" New topic

Java Networking

Anirban dutta
Ranch Hand

Joined: Aug 08, 2002
Posts: 89
Dear all,
Can anyone please tell me if there is any way to find the names of all the computers in a LAN through Java API.
Actually I have to make a customized NetSend program for which I have to gather all the computer names in a LAN.
James Swan
Ranch Hand

Joined: Jun 26, 2001
Posts: 403
I'm thinking you might have to resort to performing a "Runtime.exec()" of the "net view" windows command and parse the results to get the computer names (assuming your on windows platform).
[ April 09, 2003: Message edited by: James Swan ]
Anirban dutta
Ranch Hand

Joined: Aug 08, 2002
Posts: 89
Thanks, It worked.
It is sorta covered in the JavaRanch Style Guide.
subject: Java Networking
Similar Threads
List all available sql server running on my lan/network
how to get ip addresses of clients under LAN
Connect to the selected active client using RMI
Fetching all ip addresses in LAN
how to identify the systems which are connected in java