Sometimes you might be doing everything right, but still the text you need might not be written to the file using bufferred/printwriter in java. The reason is that you might not have flushed the stream for the data to be written to the file. you can do it by using:
BufferedWriter bw = new BufferedWriter(new FileWriter(C:/Documents and Settings/KDarshan/My Documents/Buy/Technical Specifications/testKCAVVerify.txt));
while(….)
{
……….. some logic
bw.flush();
}
Leave a Reply