Several years ago I picked-up a workbook here (or maybe from another forum) that was developed as a vehicle mileage log. It uses Data Validation | Custom | Formula to insure the beginning mileage is equal to or greater than the ending mileage for a particular vehicle’s prior entry in the log.
I have attached an abbreviated version of the workbook. The formula is =G14>=MAX(IF($C$3:$C13=$C14,$H$3:$H13)). It works great! However, each time the workbook is opened, the user must highlight cells G4:G16 (where the Data Validation’s custom formula is applied), then open the Data Validation dialog box and click the OK button. The formula is there, so you don’t have to do anything but click the OK button.
I don’t recall exactly why you go through this process of selecting the cells and opening the Data Validation dialog box, etc., but I know if you don’t, the validation process will not work. It appears Excel does not retain the Data Validation’s formula and I assume this process is reapplying the Data Validation’s formula to those cells. Or that’s the case in Excel 2010.
As long as I was the only user inputting data into the workbook, remembering to reapplying the formula was not a problem. However, recently my wife started entering data as well. She often forgets to go through the process to reapply the formula; this allows her to enter a beginning odometer that’s earlier than the last ending odometer reading; which she’s prone to do.
Here’s an example, if you open the attached workbook and enter a vehicle in C14 (select from drop-down list: Vehicle 1) and enter a Beginning Odometer mileage of 105,300 (G14), the data entry is accepted. In reality this should not be possible because the prior Ending Odometer for Vehicle 1 was 105,306 (G11). Now, if you highlight G4:G16, then then open the Data Validation dialog box and click the OK button and use the same example, when you attempt to enter 105,300 in G11 you receive appropriate warning message associated with the Data Validation’s formula.
Sorry to be so long winded, but I hope someone will have a suggestion or alternative method to accomplish this task (other than to ensure my wife enters the correct data or remembers the process to reapply the Data Validation’s formula…Ha!).
Thank you.