filename="/home/user/account.sav";
BufferedWriter writer=new BufferedWriter(new FileWriter(filename));
writer.write("whatever you want to write to the line"); writer.newLine();
//finally after u finish
writer.close();
use your own file name... windows file name like "C:/myfolder/saveing.sav";
or relative file locations...
and remember the call function must "throws IOException"