I written a server class that simply writes the numbers and the client simply reads those numbers and prints them. When I run the both client and server on tha same machine there is no data loss found. But when I run the server on different machine than client I found heavy dataloss.(while theserver written numbers from 1-9000 the client is able read only 6000 plus). The data loss is increased when the data read from the server socket created by the VB application. Here with i am pasting the code snippet for the Server and the Client java files . Please help me in solving this problem.
public class Server
public static void main(String args) throws Exception
ServerSocket server = null;
server = new ServerSocket(3333);
Socket s = server.accept();
ObjectOutputStream os = new ObjectOutputStream(s.getOutputStream());
int i =1;