Share via

Conditional formatting across two data sets

Anonymous
2024-06-03T17:55:42+00:00

I have data sets with matching criteria. One with values already filled in- budget. One with no values yet- spend. I'd like to format the spend cells to automatically type in green font if the amount is less than or equal to the corresponding budget cell, and red if greater than. They're on the same sheet. I can do it for each cell but can't figure out how to do it over the whole area without having to do one by one.

Microsoft 365 and Office | Excel | For business | Windows

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments

Answer accepted by question author

HansV 462.6K Reputation points
2024-06-03T19:34:45+00:00

Select B46:E77. B46 should be the active cell in the selection.

Set the font color to red. This will be the default.

On the Home tab of the ribbon, click Conditional Formatting > New Rule...
Select 'Format only cells that contain'.
Leave the first drop down set to 'Cell Value'.
Select 'less than or equal to' from the second drop down.
In the box next to it, enter the formula

=B3

Click Format...
Activate the Font tab.
Select green as text color.
Click OK, then click OK again.

Was this answer helpful?

2 people found this answer helpful.
0 comments No comments

Answer accepted by question author

Anonymous
2024-06-03T19:37:23+00:00

Select from B46 to E77, then use CF twice, both time using the formula option.

For the first, use the formula

=B46<=B3

and select the green font that you want as the format.

For the second, use the formula

=B46>B3

and select the red font that you want as the format.

Was this answer helpful?

1 person found this answer helpful.
0 comments No comments

2 additional answers

Sort by: Most helpful
  1. Anonymous
    2024-06-04T12:33:13+00:00

    Thank you!

    Was this answer helpful?

    0 comments No comments
  2. Anonymous
    2024-06-04T12:33:00+00:00

    Thank you!

    Was this answer helpful?

    0 comments No comments