I have a frmReservationEntry whose data source is qryCustomerSorted. Among the fields on the form are CustomerStatus, CustomerID, ReservationNumber (alphanumeric field), ResBegDate, ResEndDate. There are 7 CustomerStatus codes.
When entering data, I want to perform some validation tests.
1. If CustomerStatus is any of the 1st five fields, I want to prevent any entry into the ReservationNumber, ResBegDate, and ResEndDate fields
2. If CustomerStatus is 6, I want to insure that the ReservationNumber is 11 characters long.
3. If CustomerStatus is 7, I want to make ReservationNumber equal to the CustomerID number
4. If ReservationNumber is populated, then dates must be entered into ResBegDate and ResEndDate fields
Any suggestions as to the best place to perform these tests and the syntax would be greatly appreciated.
Tom