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. site is very good explanation is very clear throug
View Tutorial          By: sridevi at 2013-03-20 15:26:29

2. sooooooooooooooooo gr8 jop!!
View Tutorial          By: monti at 2011-06-14 08:40:55

3. The example given here are simple and easy to run
View Tutorial          By: Kranti at 2012-04-26 10:18:34

4. i am getting the following error when i ran this p
View Tutorial          By: nancy kapoor at 2008-10-07 14:26:21

5. Pls put all this code in one folder(Full project d
View Tutorial          By: Guruprasada at 2011-09-15 07:27:57

6. int n = 0;
for (int m = 0; m < 5; m++) {

View Tutorial          By: max at 2011-05-26 09:41:26

7. easy.......
View Tutorial          By: Suman at 2011-07-20 07:04:28

8. Hi! I'm working on Ubuntu 10.04

At

View Tutorial          By: Rushabh at 2011-01-12 06:22:43

9. thanks for to solve my doubts
View Tutorial          By: puttaswamy B S at 2010-09-28 00:45:47

10. Great Help...
View Tutorial          By: adity at 2012-04-27 05:34:26