Reading and writing
posted 13 years ago
I am new to using sockets but I have a simple server socket running and a client socket which reads what the servers writes (using the writeUTF() method of DataOutputStream). This works fine but I've been trying to get it to work the other way at the same time - where the client writes a message to the server and I can display it on the server side. Basically I have input and output objects in both the server and the client socket objects. I'm getting exceptions when I try all of this so my question is; is this possible at all and if it is, how do I go about doing it?