ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   how can i use countif to count sundays in excel (https://www.excelbanter.com/excel-worksheet-functions/218812-how-can-i-use-countif-count-sundays-excel.html)

Reverend Ken

how can i use countif to count sundays in excel
 
I tried COUNTIF(A4:A34,WEEKDAY()=1) it returned 0 a;though there were 4
Sundays in the Month Listed. and these were in the form of WEEKDAY()=1

What am i doing wrong in entering the formula

Glenn

how can i use countif to count sundays in excel
 
Reverend Ken wrote:
I tried COUNTIF(A4:A34,WEEKDAY()=1) it returned 0 a;though there were 4
Sundays in the Month Listed. and these were in the form of WEEKDAY()=1

What am i doing wrong in entering the formula



=SUMPRODUCT(--(WEEKDAY(A4:A34)=1))


All times are GMT +1. The time now is 04:09 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com