Added Error checking for keypress
really the tag for project 1 this time.