Catching the event that an unexpected value is used