Error Messages

Added validation with error messages.