Comment on Tutorial - FileReader and FileWriter example program in Java By Tamil Selvan



Comment Added by : Chezhian TK

Comment Added at : 2010-10-14 21:40:16

Comment on Tutorial : FileReader and FileWriter example program in Java By Tamil Selvan
Simple file writer example. .............

import java.io.BufferedWriter;
import java.io.FileWriter;

public class FileWriterDemo {
public static void main(String args[]) throws Exception
{

FileWriter fw = new FileWriter("mytest.txt");
BufferedWriter bw = new BufferedWriter(fw);
bw.write("test2");
bw.close();
fw=null;

}
}


View Tutorial



Subscribe to Tutorials

Related Tutorials

Program using concept of byte long short and int in java

Update contents of a file within a jar file

Tomcat and httpd configured in port 8080 and 80

Java File

Java String

Count number of vowels, consonants and digits in a String in Java

Reverse a number in Java

Student marks calculation program in Java

Handling Fractions in Java

Calculate gross salary in Java

Calculate average sale of the week in Java

Vector in Java - Sample Program

MultiLevel Inheritance sample in Java

Multiple Inheritance sample in Java

Java program using Method Overriding

Archived Comments

1. I entered four different objects into an ArrayList
View Tutorial          By: ADC at 2010-02-25 18:43:32

2. Nice one , Compailed no Errors ... but when execut
View Tutorial          By: Diamant at 2012-12-04 00:17:11

3. it was very good explanation hope all links give s
View Tutorial          By: ravi at 2010-08-26 10:19:48

4. good explanation,
Thanks

View Tutorial          By: venkatesh at 2012-01-04 08:43:48

5. The textarea value(finalresult) i want save in Tre
View Tutorial          By: anbalagan.s at 2007-10-17 05:10:19

6. Thanks for the clear explanation..
Really h

View Tutorial          By: Swj at 2011-12-30 05:55:26

7. Hi VIKRAM, You cannot use your sim card number the
View Tutorial          By: Ramlak at 2007-03-29 00:38:55

8. can you non grab the data direct from the vector w
View Tutorial          By: paul at 2013-08-30 11:22:04

9. Hi,
I want to write an Android Application,

View Tutorial          By: Kara at 2014-11-20 07:39:03

10. Your post was very informative... Thanks a lot. My
View Tutorial          By: Rohit Shaw at 2010-04-12 04:29:02