This chapter explores a very useful Excel feature known as data validation. Data validation enables you to add useful dynamic elements to your worksheet without using any macro programming.
Excel’s data validation feature enables you to set up certain rules that dictate what can be entered into a cell. For example, you may want to limit data entry in a particular cell to whole numbers between 1 and 12. If the user makes an invalid entry, you can display a custom message, such as the one shown in Figure 25.1.
Figure 25.1. Displaying a message when the user makes an invalid entry.
Excel makes it easy to specify the validation criteria, and you can also use a formula for more complex criteria.
The data validation suffers from a potentially serious problem: If the user copies a cell that does not use data validation and pastes it to a cell that does use data validation, the data validation rules are deleted. In other words, the cell then accepts any type of data.
To specify the type of data allowable in a cell or range, follow these steps:
Select the cell or range.
Choose Data Data Tools Data Validation. Excel displays its Data Validation dialog box.