getappt() now the working