// fill textareas with old entries
if(action != null && action.equals("edit")){
req.setAttribute("edit", "edit");
Key noteKey = KeyFactory.stringToKey(keyString);
try {
DAOFactory df = DAOFactory.getInstance();
NotesDAO notesDAO = df.getDAO(Note.class, NotesDAO.class);
Note note = notesDAO.loadNote(noteKey);
req.setAttribute("note",note);
} catch (DAOException e) {
errorOccured(resp);
}