Apparating and Disapparating within Hogwarts is impossible for all students and teachers. The only one with the ability to magically appear and disappear in the school is, of course, Albus Dumbledore.