How to count all Sundays in Column A with running dates in sequence.

Shananarocks

New Member
Joined
Jan 3, 2022
Messages
5
Office Version
  1. 2010
Platform
  1. Windows
This may look silly but seems that I can do VBA programming in MS Access but do not know remember how to use Excel formula.. Need answer quick. I thought of using Countif or SumProduct but have errors.
 

Excel Facts

Convert text numbers to real numbers
Select a column containing text numbers. Press Alt+D E F to quickly convert text to numbers. Faster than "Convert to Number"
theres a few way - detailed here

There are probably lots of ways to do that. Here's one

=SUMPRODUCT(--(WEEKDAY(your_range)=1))

Sunday = 1
Monday = 2 etc

Hope it helps

Lee
Book9
ABCDE
1
21/1/24MondayThere are probably lots of ways to do that. Here's one
31/2/24Tuesday
41/3/24Wednesday3
51/4/24Thursday
61/5/24FridaySunday = 1
71/6/24SaturdayMonday = 2 etc
81/7/24Sunday
91/8/24MondayHope it helps
101/9/24Tuesday
111/10/24WednesdayLee
121/11/24Thursday
131/12/24Friday
141/13/24Saturday
151/14/24Sunday
161/15/24Monday
171/16/24Tuesday
181/17/24Wednesday
191/18/24Thursday
201/19/24Friday
211/20/24Saturday
221/21/24Sunday
Sheet1
Cell Formulas
RangeFormula
E4E4=SUMPRODUCT(--(WEEKDAY(A1:A31)=1))
B2:B22B2=A2
 
Upvote 0
Solution
theres a few way - detailed here


Book9
ABCDE
1
21/1/24MondayThere are probably lots of ways to do that. Here's one
31/2/24Tuesday
41/3/24Wednesday3
51/4/24Thursday
61/5/24FridaySunday = 1
71/6/24SaturdayMonday = 2 etc
81/7/24Sunday
91/8/24MondayHope it helps
101/9/24Tuesday
111/10/24WednesdayLee
121/11/24Thursday
131/12/24Friday
141/13/24Saturday
151/14/24Sunday
161/15/24Monday
171/16/24Tuesday
181/17/24Wednesday
191/18/24Thursday
201/19/24Friday
211/20/24Saturday
221/21/24Sunday
Sheet1
Cell Formulas
RangeFormula
E4E4=SUMPRODUCT(--(WEEKDAY(A1:A31)=1))
B2:B22B2=A2
Thanks for much for the quick reply. The double hyphen syntax really gets me. Appreciate!!!!!
 
Upvote 0
Thanks for much for the quick reply. The double hyphen syntax really gets me. Appreciate!!!!!

The marked solution has been changed accordingly. In your future questions, please mark the post as the solution that actually answered your question, instead of your feedback message as it will help future readers. No further action is required for this thread.
 
Upvote 0

Forum statistics

Threads
1,223,911
Messages
6,175,333
Members
452,636
Latest member
laura12345

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