Forum Discussion
BrendanKingdom
Aug 21, 2023Copper Contributor
Excel Solution Required
Hello hive mind,
I'm using Excel on a Mac.
PART ONE
So I have a cell in Excel that contains a drop down, the drop down has the options: Pass, Merit, Distinction, Fail
Later down the spreadsheet I have cells that say:
Number of Distinctions and blank cell next to it
Number of Merits and a blank cell next to it
Number of Passes and a blank cell next to it
Number of Fails and a blank cell next to it
When someone selects, say a distinction, I'd like the 'blank cell' to show it as a 1, if I get another it changes to 2 etc etc etc...
Does anyone know how this can be achieved?
PART TWO
In the exact same scenario, my team highlight various cells red or green using the 'fill' tool. Is there anyway to calculate how many reds and how many greens in total I get across a section of the spreadsheet?
Thanks to everyone who comments 🙂
Brendan
PART ONE:
Let's say the cells with the drop-down are A2:A100.
Number of cells with Distinction:
=COUNTIF(A2:A100, "Distinction")
And similar for the other options.
PART TWO:
If the cells are colored directly (not through conditional formatting), counting cells with a specific color requires VBA, so all users would have to allow macros. And it would only work in the desktop version of Excel for Windows and Mac, not in Excel Online, nor on iOS/Android.
Do you really want this?
- BrendanKingdomCopper ContributorThanks Hans, hmmm... with regard to Part Two, I don't know what VBA is, but basically in the cell there is a deadline date, my team colour it red if it's not been met and green if it has, I simply wanted to output the number of green cells and the number of reds, is there another way to do this?
Thank you in advanceIf the cell is colored red when the deadline date has been passed, you could use a conditional formatting rule to so.
And you could use a COUNTIF formula that looks at the dates to count those that have passed.
If necessary, you could use another column to record additional needed information.
Without knowing the setup, it's difficult to provide more detailed help.