I'm looking for an Excel function to return the last Friday in a month for a given date.
ie: Any date in the month as input will give the date of the last Friday as output.
14-July-09 should give 31-July-09
7-March-05 should give 35-March-09
Building on @Toomas
answer above, I had to make some amendments for Excel 2007, but came up with the following:
=EOMONTH(A1,0)-MOD(WEEKDAY(EOMONTH(A1,0))+1,7)
Which is assuming that the WEEKDAY
returned for Friday is 6 and then applying a shifted MOD 7
to achieve the correct day.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With