dcsimg
InetAddress.getHostName() question
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Blue_Milk
Posted On:   Wednesday, July 31, 2002 08:54 AM

when i try to use this segment of code...

InetAddress inet = new InetAddress();
String ip = inet.getHostName();

it returns an "InetAddress() is not public in java.net.InetAddress; cannot be accessed from outside package".

what is the problem with the code.
anyway.. is this the correct way of determining the IP address in which this java file is currently running in?

Re: InetAddress.getHostName() question

Posted By:   Blue_Milk  
Posted On:   Wednesday, July 31, 2002 09:01 AM

ok. i found out the problem with the code already.
guess i wouldn't be needing your help now
:)
About | Sitemap | Contact