+ Reply to Thread
Results 1 to 3 of 3

Autocalculating end of month dates

  1. #1
    Registered User
    Join Date
    05-24-2004
    Posts
    16

    Autocalculating end of month dates

    If I input a date,
    I need to be able to calculate the last workday of the month for the next 12 months.
    For example, if I put in 2/28/05,
    I need to see:
    3/31/05
    4/29/05
    5/31/05
    .
    .
    .
    2/28/06

    I can't use the EDATE function, b/c 2/28/05 would give me 3/28/05 and not 3/31.

    Any help would be appreciated!
    Thanks.

  2. #2
    Forum Contributor
    Join Date
    04-30-2004
    Posts
    122
    Hi! If you have the first date in cell A1 (say 01/31/05), you can copy this formula down the A column and it should give you what you want.......

    =IF(WEEKDAY(DATE(YEAR(A1),MONTH(A1)+2,1)-1,2)>5,DATE(YEAR(A1),MONTH(A1)+2,1)-WEEKDAY(DATE(YEAR(A1),MONTH(A1)+2,1)-1,2)+4,DATE(YEAR(A1),MONTH(A1)+2,1)-1)

    Hope this helps!

  3. #3
    Registered User
    Join Date
    05-24-2004
    Posts
    16
    it works perfectly
    thanks, rutgers!

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1