This week's book giveaway is in the Jobs Discussion forum.
We're giving away four copies of Soft Skills and have John Sonmez on-line!
See this thread for details.
The moose likes Sockets and Internet Protocols and the fly likes Writing to files using socket server Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Soft Skills this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Java » Sockets and Internet Protocols
Bookmark "Writing to files using socket server" Watch "Writing to files using socket server" New topic
Author

Writing to files using socket server

Patrick Boos
Greenhorn

Joined: Sep 09, 2008
Posts: 15
Hello,
I am having a problem writing to a file on a socket client/server application. I can send the data from a JTextArea to the server, it appears to read the text, but I cannot seem to get the server to write the data to the .txt file. Here is the server code:



Thank you.
Rusty Shackleford
Ranch Hand

Joined: Jan 03, 2006
Posts: 490
Too much irrelevant code to comb through.

You best bet is to put a println statement right were the sever receives the string, and see if it did in fact get it. If it did, then move it along the path of execution to see where something went wrong.


"Computer science is no more about computers than astronomy is about telescopes" - Edsger Dijkstra
vinoth sathiyamoorthy
Ranch Hand

Joined: Sep 30, 2008
Posts: 31
do you want save the read file?
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Writing to files using socket server