Thread: Sunday
View Single Post
  #8   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Ron Rosenfeld Ron Rosenfeld is offline
external usenet poster
 
Posts: 5,651
Default Sunday

On Sun, 30 Mar 2008 12:04:43 +0100, "Dale" wrote:

This is probably a very basic question so I apologise first, how would I
calculate the last sunday of a given month? Once I have that date, I need
the following Friday......

Thanks


If you have Excel 2007, or in an earlier version, if you have the Analysis
ToolPak installed, with any date in A1,you can use:

Sunday

=EOMONTH(A1,0)+1-WEEKDAY(EOMONTH(A1,0))

For the following Friday, merely add 5 to the above

=EOMONTH(A1,0)+6-WEEKDAY(EOMONTH(A1,0))

If you get a #NAME error, check HELP for EOMONTH and it will tell you what to
do.
--ron