I am new Socket programming and i try to write chat program (client/server)
and programs shot this Exeption
Exception Occured: java.net.UnknownHostException
Why shot i dont know :(
Socket toServer=new Socket("machine-name",1001);
"machine-name" is probably not a real host. You need to have the exact host name or its IP address.
If your trying to connect to localhost try "127.0.0.1"
Try using "\\machine-name"
Make sure you are on the same network.