I have a code snippet that writes in TXT, it works however it deletes what was written before, how do I make it not replace what was already written?
Here's the snippet of code I'm using:
public class TestandoEscrita {
public static void main(String[] args) throws FileNotFoundException {
PrintStream out = new PrintStream("c:/EscritaUrna.txt");
Locale locale = new Locale("pt","BR");
GregorianCalendar calendar = new GregorianCalendar();
out.println("Voto Computado Dia");
SimpleDateFormat formatador = new SimpleDateFormat("dd' de 'MMMMM' de 'yyyy' - 'HH':'mm'h'",locale);
out.println(formatador.format(calendar.getTime()));
out.close();
}
}