Introduction
Writing to a metwork socket is very similar to writing to a file as you can see in the example below. It now only gets the OutputStream from the socket.
try { BufferedWriter wr = new BufferedWriter(new OutputStreamWriter(socket.getOutputStream())); wr.write("aString"); wr.flush(); } catch (IOException e) { }