hi guys , i have a query
if some group of people are using the same java application and are connected via LAN . It is like in the java application , i want to expose other people ip address , so that i am able to send message via LAN .
you guys got any idea how shd i code it ?

Recommended Answers

All 3 Replies

here's the method:

try {
          InetAddress inetAdd =
              InetAddress.getByName(input.getText());
          output.setText(inetAdd.getHostAddress());
        }
        catch (Exception e1)
        {
          output.setText("ERROR");
        }
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.