try {
FileWriter fichero = new FileWriter("D:\\auditoria.txt", true);
PrintWriter pw = new PrintWriter(fichero);
String userData = "contenido";
pw.println(userData);
fichero.close();
} catch (IOException e) {}