Hi Ranchers,
This is a simple one-way interaction (from server to client) client-server program that makes changes on the client-side on the basis of whatever is being sent from the socket over server-side. There is absolutely no issue on the server but on the client-side, BufferedReader's readLine() method is giving "null" even when nothing is being sent over the socket from server-side. I've read the article Don't println() to a socket in I/O FAQs and tried implementing the solution provided but unfortunately the issue remains unsolved. Here, I've also marked where exactly the problem is coming (on the client-side) as you move along the code which is as follows:
Server-side code:
Client-side code:
This class is on client-side.
If you wish to run this, create a file "MappingFile.txt" & fill it line-by-line such that x1:1 and so on till x8:8
And yes, I'm using Windows OS.
Thanks..
This is a simple one-way interaction (from server to client) client-server program that makes changes on the client-side on the basis of whatever is being sent from the socket over server-side. There is absolutely no issue on the server but on the client-side, BufferedReader's readLine() method is giving "null" even when nothing is being sent over the socket from server-side. I've read the article Don't println() to a socket in I/O FAQs and tried implementing the solution provided but unfortunately the issue remains unsolved. Here, I've also marked where exactly the problem is coming (on the client-side) as you move along the code which is as follows:
Server-side code:
Client-side code:
This class is on client-side.
If you wish to run this, create a file "MappingFile.txt" & fill it line-by-line such that x1:1 and so on till x8:8
And yes, I'm using Windows OS.
Thanks..