I've created this method to append strings but it throws
an exception when I try to use it:
fdf.append(orm) ;
orm is a string.
an exception when I try to use it:
fdf.append(orm) ;
orm is a string.
Code:
public void append(String text)
{
try{
fstream = new FileWriter(file);
BufferedWriter file = new BufferedWriter(fstream);
file.append(text);
file.close();
}
catch (Exception e) {
System.err.println("Error: can't append");
}
}
Comment