Hi All, Attempting to Read a file and write it using Thread Following is my implementation:
in_file and out_file are obtained as below: (In the Constructor of the Thread Class.
Now, following is the code in the main method of CopyFiles class which runs this Thread:
In place of INPUTFILE and OUTPUTFILE I have given FULL PATH of the files.
My input file is having only 5 rows as below:
The code is excuting without errors but NONE OF THE ROWS is getting written.. I have checked by debugging the code in Eclipse and even the While loop in RUN method is working but no out put is getting written.... Can someone point out the problem??
Joined: Sep 14, 2006
Ahhhh..... My appologies... The code was behaving like that because I DIDNT CLOSE THE STREAMS AFTER THE LOOP.... By putting the statements:
I was able to make the code work...
Moderators/Admins....Will you kindly close this thread?
subject: Attempting to Copy Files using Threads...