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



Comment Added by : Tim

Comment Added at : 2009-10-21 17:31:00

Comment on Tutorial : FileReader and FileWriter example program in Java By Tamil Selvan
Nice example for FileReader and FileWriter,

The FileWriter code needed to be tweeked though,

FileWriter f2 = new FileWriter("file3.txt");
f2.write(buffer,buffer.lengthbuffer.
length/4,buffer.length/4);
f2.close();

The f2.write(buffer,buffer.length/4,buffer.length/4) works
better, I couldn't find a method for FileWriter.write() that took
4 arguments....


View Tutorial



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. vry nice example....thanx..
View Tutorial          By: rekha at 2010-09-14 11:55:38

2. dear sir ,
How can i create my smtp or host

View Tutorial          By: jignesh at 2011-03-14 01:42:11

3. The tutorial, it's very easy to be understood

View Tutorial          By: newcomer at 2012-04-25 03:49:35

4. finally an understandable example
View Tutorial          By: sdf at 2012-11-26 21:44:34

5. Most Our friends ask About error occurred during t
View Tutorial          By: Chala G. at 2015-01-13 16:52:10

6. only last code is gud one (DateFormat )... otherwi
View Tutorial          By: Gaurav at 2013-01-04 09:18:43

7. Very good explanation . I was very confuse but rea
View Tutorial          By: Shahabaj at 2010-08-10 08:58:39

8. THIS IS VERY SIMPLE AND EXCELENT PROGRAM.THIS PROG
View Tutorial          By: CHIRANJEET at 2011-02-05 12:13:54

9. Can please send me codes to pass strings or text f
View Tutorial          By: bryan at 2009-12-29 05:59:21

10. can u give a gud example on command line arguments
View Tutorial          By: shravan at 2010-04-09 23:11:18