1. Conditional Formatting – based on values in cells

Take a range of cells with values that you wish to format.
2. Select Conditional Formatting

First, select/highlight the range of cells that you wish to format.
From the Format menu, select “Conditional Formatting”
3. Set the Rules for the Formatting

Set the rules that need to be met in order to apply the format.
Eg. If the cell value is greater than 9, then a different format will be applied.
4. You can set multiple rules

You can set up more than one rule, and apply a different format to each rule.
5. Create New Cell Styles

Click on “New Style”
Name the new style that you want to apply for the rule
Then change the format to meet your needs.
For example, I am going to make the background green for all cells that have a value greater than 9, and any less than or equal to 3 will be highlighted with yellow. So I am creating New Styles, which I call green_bk and yellow_bk, which will be applied to each rule.
Click on OK when you’re done.
6. Apply the Styles Based on Rules

You will then have a spreadsheet that has styles applied depending on the value in the cell.
Microsoft Office
If you are after a Microsoft Excel version of this tutorial, then there is an excellent one over at WikiHow.



[...] So all that was left for me to do was to test each date in row 3 against the task start and end dates, and return a 1 or 0 to the cell. Then I could tell the spreadsheet to format the cell depending on the value returned. This resulted in bars. If you are not sure about conditional formatting, check out my post on conditional formatting. [...]