bottom
Great ExcelTips!
         
Your e-mail address is safe!
Close Note

Tips.Net > ExcelTips Home > Formatting > Conditionally Formatting an Entire Row

Conditionally Formatting an Entire Row

Summary: Conditional formatting is a great tool, allowing you to adjust formatting dynamically based on the contents of your worksheet. Sometimes it can be confusing to put together a conditional format that affects more than just a single cell, as in the case of a format to be applied to an entire row. (This tip works with Microsoft Excel 97, Excel 2000, Excel 2002, and Excel 2003.)

Graham described a problem he was having with a worksheet. He wanted to use conditional formatting to highlight all the cells in a row, if the value in column E was greater than a particular value. He was having problems coming up with the proper way to do that.

Suppose for a moment that your data is in cells A3:H50. You can apply the proper conditional formatting by following these steps:

  1. Select cell A3.
  2. With A3 still selected, scroll the worksheet so you can see cell H50.
  3. Hold down the Shift key as you click on H50. The entire range A3:H50 should be selected, and A3 should still be the active cell.
  4. Choose Conditional Formatting from the Format menu. Excel displays the Conditional Formatting dialog box.
  5. In the left-most drop-down list for Condition 1, select Formula Is. (Click here to see a related figure.)
  6. In the formula space just to the right of the drop-down list, enter the following formula:
     =$E3>40000
  1. Click the Format button. Excel displays the Format Cells dialog box. (Click here to see a related figure.)
  2. Using the controls in the dialog box, specify how you want the cells that are greater than 40,000 to be displayed.
  3. Click OK to dismiss the Format Cells dialog box.
  4. Click OK to accept your conditional format.

This formula works because you use the absolute indicator (the dollar sign) just before the column letter. Any reference that has the $ before it is not changed when Excel propagates it throughout a range. In this case, the cell reference will always be to column E, although the row portion of the reference can change.

Tip #2798 applies to Microsoft Excel versions: 97 | 2000 | 2002 | 2003


PivotTables Got You Perplexed? Learn the ins and outs of this powerful data-crunching tool. ExcelTips: PivotTables for the Faint of Heart makes it easy.

Helpful Links

Ask an Excel Question
Make a Comment

Tips.Net Home
Vital News Home

ExcelTips FAQ
ExcelTips Premium

Learn Access Now

Beauty Tips
Bugs and Pests Tips
Car Tips
Cleaning Tips
College Tips
Cooking Tips
Excel2007 Tips
ExcelTips
Family Tips
Gardening Tips
Health Tips
Home Tips
Money Tips
Organizing Tips
Pet Tips
Word2007 Tips
WordTips

Advertise on the
ExcelTips Site

 

Great Info!

Get tips like this every week in ExcelTips, a free productivity newsletter. Enter your e-mail address and click "Subscribe."
     
(Your e-mail address will never be shared with anyone, ever.)