B
Bob
For a given Year and Month, I need to find either the 3rd Sunday (if month =
Jan thru Oct) or the 2nd Sunday (if month = Nov or Dec).
Example:
Year = 2009
Month = 7
3rd Sunday in July 2009 = 7/19/2009
There are two additional rules that also need to be taken into account:
If the 1st of the month is Saturday, that weekend is counted as the 1st
weekend of the month. However, if the 1st of the month is Sunday, that
weekend is counted as the 5th weekend of the previous month.
Example:
Year = 2009
Month = 11
2nd Sunday in November 2009 = 11/15/2009
Any help in coming up with a formula that takes into account the
aforementioned 4 rules would be greatly appreciated.
Thanks,
Bob
Jan thru Oct) or the 2nd Sunday (if month = Nov or Dec).
Example:
Year = 2009
Month = 7
3rd Sunday in July 2009 = 7/19/2009
There are two additional rules that also need to be taken into account:
If the 1st of the month is Saturday, that weekend is counted as the 1st
weekend of the month. However, if the 1st of the month is Sunday, that
weekend is counted as the 5th weekend of the previous month.
Example:
Year = 2009
Month = 11
2nd Sunday in November 2009 = 11/15/2009
Any help in coming up with a formula that takes into account the
aforementioned 4 rules would be greatly appreciated.
Thanks,
Bob