In Access 2003 you can enable automatic error checking of reports. Error checking not only points out errors in a report, but also provides suggestions for correcting them.
You can activate error checking from the Error Checking tab under Tools, Options (see Figure 10.5). Click the Enable Error Checking check box to enable error checking. After you enable error checking, indicators appear on your report, letting you know that something is wrong (see Figure 10.6). You then click the indicator, and an explanation along with suggestions for correcting the error appear (see Figure 10.7).
The error checker will identify several categories of errors, which appear in Table 10.2.
Category | Description |
---|---|
Unassociated label and control | You select a label and a control (for example, a label and a text box) that are not associated with one another. |
New unassociated labels | You add a label that is not associated with another control. |
Invalid control properties | The string in the control source is not valid. This could be because it is not a valid field name, or because the control source refers to itself. It can also be because the expression does not begin with an equal sign, or because the option value in an option group is not unique. |
Other common errors | The report has an invalid sorting or grouping definition, or is wider than the selected paper size. |
If Access identifies several errors for the same control, the error indicator remains until all errors are corrected. If you choose to ignore an error, simply select the Ignore Error option on the Error Checking Options menu. This will clear the error indicator until you close and open the report again. Remember that you can turn off error checking entirely via Tools, Options (although I find this feature to be extremely valuable).