Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
ksp
 
Posts: n/a
Default Formula for Calculating a Floating Date


Hi All

I need a formula to calculate a floating date - the last Saturday in
September

If found this formula on another site, but couldn't seem to get it to
work.

=SUM((WEEKDAY(DATE(B3,C3,(ROW(INDIRECT(
"1:"&DAY(DATE(B3,C3+1,0)))))))=D3)*1)

Where B3 is the year, C3 is the month, and D3 is the day of week
(1=Sunday, 2=Monday, ..., 7=Saturday

Any help in either what I have done wrong or an alternative formula
would be appreciated.

Ta

Karen


--
ksp
------------------------------------------------------------------------
ksp's Profile: http://www.excelforum.com/member.php...fo&userid=6267
View this thread: http://www.excelforum.com/showthread...hreadid=398010

  #2   Report Post  
Blue Hornet
 
Posts: n/a
Default

Assuming a "year" in cell A1 (like 2005, 2004, 2003, etc.), this will
work to find the "last Saturday in September" in the year in A1:

=IF( WEEKDAY( DATE( A1, 9, 30)) < 7, DATE( A1, 9, 30) - WEEKDAY( DATE(
A1, 9, 30)), DATE( A1, 9, 30))

Chris

ksp wrote:
Hi All

I need a formula to calculate a floating date - the last Saturday in
September

If found this formula on another site, but couldn't seem to get it to
work.

=SUM((WEEKDAY(DATE(B3,C3,(ROW(INDIRECT(
"1:"&DAY(DATE(B3,C3+1,0)))))))=D3)*1)

Where B3 is the year, C3 is the month, and D3 is the day of week
(1=Sunday, 2=Monday, ..., 7=Saturday

Any help in either what I have done wrong or an alternative formula
would be appreciated.

Ta

Karen


--
ksp
------------------------------------------------------------------------
ksp's Profile: http://www.excelforum.com/member.php...fo&userid=6267
View this thread: http://www.excelforum.com/showthread...hreadid=398010


  #3   Report Post  
ksp
 
Posts: n/a
Default


Thanks Chris that worked a treat

Much appreciated


--
ksp
------------------------------------------------------------------------
ksp's Profile: http://www.excelforum.com/member.php...fo&userid=6267
View this thread: http://www.excelforum.com/showthread...hreadid=398010

  #4   Report Post  
Ron Rosenfeld
 
Posts: n/a
Default

On Mon, 22 Aug 2005 21:47:29 -0500, ksp
wrote:


Hi All

I need a formula to calculate a floating date - the last Saturday in
September

If found this formula on another site, but couldn't seem to get it to
work.

=SUM((WEEKDAY(DATE(B3,C3,(ROW(INDIRECT(
"1:"&DAY(DATE(B3,C3+1,0)))))))=D3)*1)

Where B3 is the year, C3 is the month, and D3 is the day of week
(1=Sunday, 2=Monday, ..., 7=Saturday

Any help in either what I have done wrong or an alternative formula
would be appreciated.

Ta

Karen


With any date in the desired month in A1:

=A1-DAY(A1)+33-DAY(A1-DAY(A1)+32)-
WEEKDAY(A1-DAY(A1)+33-DAY(A1-DAY(A1)+32))

or:

=DATE(YEAR(A1),MONTH(A1)+1,1)-
WEEKDAY(DATE(YEAR(A1),MONTH(A1)+1,1))


--ron
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Formula checking multiple worksheets sonic-the-mouse Excel Worksheet Functions 2 June 5th 05 03:28 AM
addition to my date formula...required Juco Excel Worksheet Functions 5 January 30th 05 11:48 AM
Excel formula with date constraints Warrior Pope Excel Discussion (Misc queries) 3 January 28th 05 03:08 PM
Formula with date constraints Warrior Pope Excel Worksheet Functions 1 January 28th 05 02:11 PM
Need help troubleshooting an array formula XLXP on Win2K KR Excel Worksheet Functions 1 December 13th 04 07:41 PM


All times are GMT +1. The time now is 07:26 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"