Log in

View Full Version : How to use both Printwriter and BufferedOutputStream at same time in Java Socket Pgm?


Rajeev18991
Aug 22, 2013, 03:50 AM
Im developing a project in wireless sensor network, here I need to know all clients connected with server, so, whenever server sending message, I have attached clients name in the form of regular expression, after that the client extract the each clients name and display in its own window. . So for that I'm using Printwriter, but I want to send a file too.. that is I'm sending in the form of bytes, so the printwriter getting single line only, so I'm using BufferedOutputStream. .
All are working fine, but client not sending bytes as well as the server not listening for file. . That is my problem. .

Please anyone help me..