Excel formulas

Copper Contributor

so i have to count in a1 sheet2 the values from a1:d7 from sheet1 and if those are >8 the layout has to be red. how ??

 

1 Reply

Hello,

 

Count how many cells have values or sum the values of the cells?

 

If you want to count, use Count() for numbers only and CountA() to include text and numbers in the result.

 

On Sheet2, cell A1, start typing the formula like this (assuming you want to use CountA() to include text and numbers.

 

=counta(

 

then click in Sheet1 and select the cells you want to count and hit Enter. Excel will put in the closing bracket and the formula will look like this:

 

=COUNTA(Sheet1!A1:D7)

 

If you want to ignore text, use the COUNT() function instead.

 

The next step is to use conditional formatting to turn the cell red if the result is > 8. 

 

With the cell still selected, click Conditional Formatting on the Home ribbon. Click Highlight Cells RulesGreater Than and type in the value. Select a format from the dropdown and click OK.

 

Let me know if that helped.