aspose file tools*
The moose likes Beginning Java and the fly likes File writing Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "File writing" Watch "File writing" New topic
Author

File writing

Manoj Zachariah
Ranch Hand

Joined: Dec 08, 2003
Posts: 65
the code below rewrites the file each time, can i make it to append each time i run instead of overwriting.
Nischal Topno
Ranch Hand

Joined: Nov 24, 2001
Posts: 45
try the overloaded constructor of FileWriter(String fileName, boolean append). So in your case it will be
FileWriter fw = new FileWriter("Rule.xml", true);
Manoj Zachariah
Ranch Hand

Joined: Dec 08, 2003
Posts: 65
thanks
 
 
subject: File writing