Cant seem to count

AndyGav86

New Member
Joined
Nov 17, 2022
Messages
33
Office Version
  1. 365
Platform
  1. Windows
Hi, So I am trying to count how many male and female officers are on per shift, I have made a sheet so that the male officers are under one column and the female officers are under another then i put column next to the officers with an M or F. This is a separate sheet to the main sheet i want the number to appear


1681899780461.png


All i want to do is when i put the names in column B below i want "T1" & "V1" to display the number of how many male and females


1681899721687.png


I hope that this makes sense, I did try a countifs but didn't work

Many Thanks in advance

Andy
 

Excel Facts

Copy PDF to Excel
Select data in PDF. Paste to Microsoft Word. Copy from Word and paste to Excel.
You could try this changing sheet names/ranges to suit:

=SUM(--(IFERROR(VLOOKUP($B$4:$B$20,Sheet2!$A$2:$B$20,2,0),"")=S1))
 
Upvote 0
Thanks for that. How about
Excel Formula:
=SUM(COUNTIFS('Hidden Data'!A:A,B4:B26,'Hidden Data'!B:B,"M"))
 
Upvote 0
Solution
Glad we could help & thanks for the feedback.
 
Upvote 0

Forum statistics

Threads
1,224,753
Messages
6,180,747
Members
452,996
Latest member
nelsonsix66

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top