tags:

views:

345

answers:

1

Hi everyone,

I want to get all the usernames or IPaddresses from the LAN using java. Can anyone suggest me how to approach?

Thank you.

+2  A: 

This is a slightly strange question. What is your purpose, what do you want to do with the information? A list of user names is quite different from a list of IP addresses, it's hard to understand why either is acceptable.

Also, consider that just because an IP address "exists" on a LAN, that doesn't say anything about the type of host that has the IP address. It might not have a "user" associated with it, for instance.

For a list of IPs, try finding the subnetwork mask, and pinging the broadcast address.

unwind
sorry i thought i dont want user names.can i get the System names or computer names connected to LAN where all the sytems are under the same workgroup
Bharath
can anyone suggest me how to get the system names connected in LanThank you!!
Bharath