11.08.2013 Views

Excel's Formula - sisman

Excel's Formula - sisman

Excel's Formula - sisman

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Chapter 19: Conditional Formatting and Data Validation 535<br />

The formula must be a logical formula that returns either TRUE or FALSE. If the formula<br />

evaluates to TRUE, the condition is satisfied, and the conditional formatting is applied.<br />

If the formula evaluates to FALSE, the conditional formatting is not applied.<br />

Understanding relative and absolute references<br />

If the formula that you enter into the Conditional Formatting dialog box contains a cell reference,<br />

that reference is considered a relative reference, based on the upper-left cell in the selected range.<br />

For example, suppose that you want to set up a conditional formatting condition that applies<br />

shading to cells in range A1:B10 only if the cell contains text. None of Excel’s conditional formatting<br />

options can do this task, so you need to create a formula that will return TRUE if the cell contains<br />

text, and FALSE otherwise. Follow these steps:<br />

1. Select the range A1:B10 and ensure that cell A1 is the active cell.<br />

2. Choose Home➜Styles➜Conditional Formatting➜New Rule to display the New<br />

Formatting Rule dialog box.<br />

3. Click the rule type labeled Use a <strong>Formula</strong> to Determine Which Cells to Format.<br />

4. Enter the following formula in the <strong>Formula</strong> box:<br />

=ISTEXT(A1)<br />

5. Click the Format button to display the Format Cells dialog box.<br />

6. In the Format Cells dialog box, click the Fill tab and specify the cell shading that you want<br />

applied if the formula returns TRUE.<br />

7. Click OK to return to the New Formatting Rule dialog box (see Figure 19-16).<br />

8. Click OK to close the New Formatting Rule dialog box.<br />

Figure 19-16: Creating a conditional formatting rule based on a formula.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!