@ > Home > Contents > Count of Saturdays in August 1999 Excel 97+

Task

A1: 08/01/99, with Data Validity User defined =DAY(A1)=1, to ensure exclusive entry of a month's first only.

B1: 0 for Saturday. Friday is 6, Sunday 1. Why? =MOD(Date,7) gives this order of weekdays and can be used internationally.

Solution:

=TRUNC((DAY(A1+31-DAY(A1+31))-MOD(B1-MOD(A1,7),7)+6)/7)

Possible results: 4 or 5. Here: 4. Similar Page: 5030.htm

Individual periods:

A1: from (any date, without Data Validity!)

A2: until (later date)

B1: see above

=TRUNC((A2-A1-MOD(B1-MOD(A1,7),7)+7)/7)