Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel,microsoft.public.excel.programming,microsoft.public.excel.worksheetfunctions
external usenet poster
 
Posts: 5
Default Distributing All Days Across Months by CPearson

The formula below I have used in my worksheet is what I have copied
from Mr. Pearson's site http://www.cpearson.com/excel/distribdates.htm
(Many thanks to him and his great site), however it is based on the
Start and End date being 15-Jan-00 and 12-Jun-00 in Cel B17 and C17
respectively.

=MAX(0,(MIN($C17,DATE(YEAR(D$16),MONTH(D$16)+1,0))-MAX($B17,D$16)+1))

What would the formula be if I had several more intervals horizontally
as 09-Oct-00 and 23-Dec-00 in cell D17 and E17 and 12-Feb-01 and
06-Sep-01 in cell F17 and G17. Ofcourse the MONTHS (Jan-00,
Feb-00...Dec-00, Jan-01, Feb-01...Dec-01..) would then have to
probably start from H16 onwards. I am looking for a combined formula
considering all the intervals together. Currently I am adding the
above formula for each interval for example:

=MAX(0,(MIN($C17,DATE(YEAR(H$16),MONTH(H$16)+1,0))-MAX($B17,H$16)+1))
+ MAX(0,(MIN($E17,DATE(YEAR(H$16),MONTH(H$16)+1,0))-MAX($D17,H$16)+1))
+ MAX(0,(MIN($G17,DATE(YEAR(H$16),MONTH(H$16)+1,0))-MAX($F17,H$16)+1))

In my actual spreadsheet I have 8 such Date intervals, the formula
really gets too big. Is this the only way for me or is there a better
way

Any help would be greatly appreciated

Regards
Edward
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
Total days worked /20 to get actual months/days Cindy Excel Worksheet Functions 3 October 22nd 09 11:50 PM
distributing days KANDLEZ Excel Worksheet Functions 1 May 20th 09 02:01 AM
how do i convert a number of days to years, months & days? SafetyLen Excel Discussion (Misc queries) 1 August 23rd 07 01:34 AM
i have two days and i want the difference in days, months, year maja Excel Worksheet Functions 7 April 22nd 06 01:14 AM
convert Days to Years, Months, Days Klaudebou Excel Discussion (Misc queries) 3 December 29th 05 10:33 PM


All times are GMT +1. The time now is 07:45 PM.

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"