#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 86
Default Date Functions

I am trying to determine the date in which the 1 and 3 tuesday of the month
falls...is this possible?

Thanks for your help.
--
Jules
  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 5,651
Default Date Functions

On Wed, 5 Jul 2006 05:25:02 -0700, Jules
wrote:

I am trying to determine the date in which the 1 and 3 tuesday of the month
falls...is this possible?

Thanks for your help.


In general, the first n-day of a month can be determined by:

=A1-DAY(A1)+8-WEEKDAY(A1-DAY(A1)+1-DOW)

where A1 = any date during that month and
where DOW = Day of Week (Sun=1, Mon=2, Tues=3)

The third n-day is the above +14.

So for the first Tuesday:

=A1-DAY(A1)+8-WEEKDAY(A1-DAY(A1)-2)

Third Tuesday

=A1-DAY(A1)+22-WEEKDAY(A1-DAY(A1)-2)

If A1 is always the first day of the month, then:

First Tuesday:

=A1+7-WEEKDAY(A1-3)

Third Tuesday:

=A1+21-WEEKDAY(A1-3)


--ron
  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 86
Default Date Functions

Thank you so much!
--
Jules


"Ron Rosenfeld" wrote:

On Wed, 5 Jul 2006 05:25:02 -0700, Jules
wrote:

I am trying to determine the date in which the 1 and 3 tuesday of the month
falls...is this possible?

Thanks for your help.


In general, the first n-day of a month can be determined by:

=A1-DAY(A1)+8-WEEKDAY(A1-DAY(A1)+1-DOW)

where A1 = any date during that month and
where DOW = Day of Week (Sun=1, Mon=2, Tues=3)

The third n-day is the above +14.

So for the first Tuesday:

=A1-DAY(A1)+8-WEEKDAY(A1-DAY(A1)-2)

Third Tuesday

=A1-DAY(A1)+22-WEEKDAY(A1-DAY(A1)-2)

If A1 is always the first day of the month, then:

First Tuesday:

=A1+7-WEEKDAY(A1-3)

Third Tuesday:

=A1+21-WEEKDAY(A1-3)


--ron

  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 5,651
Default Date Functions

On Wed, 5 Jul 2006 08:06:01 -0700, Jules
wrote:

Thank you so much!
--
Jules


You're welcome.

Glad to help.
--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
Advanced Date Functions enright_m Excel Worksheet Functions 1 October 26th 05 04:08 PM
NETWORKDAYS - Multiple Date Selection Annabelle Excel Discussion (Misc queries) 3 October 4th 05 07:04 PM
How do I calculate if a date is in a certain time frame? Pe66les Excel Worksheet Functions 19 August 27th 05 11:07 PM
Date functions John New Users to Excel 3 August 15th 05 08:50 PM
search for latest date Sue Excel Worksheet Functions 2 August 2nd 05 11:09 PM


All times are GMT +1. The time now is 11:51 AM.

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

About Us

"It's about Microsoft Excel"