View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.misc
Sandy Mann Sandy Mann is offline
external usenet poster
 
Posts: 2,345
Default Calculating Months within a specific period

With your Contract start date in A3, the Contract end date in B3 and 2007,
2008, 2009, 2010, 2011 etc in C1:F1 respectively then try:

In C3 enter the formula:

=IF($A$3<DATE(C1,4,1),DATEDIF($A$3,DATE(C1,4,1),"m "),"")

then in D3:

=IF(AND($B$3DATE(C1,4,1),$A$3<DATE(D1,4,1)),DATED IF($A$3,MIN($B$3,DATE(D1,4,1)),"m")-SUM($C$3:C3),"")

and drag across as far as year dates are in Row 1

--
HTH

Sandy
In Perth, the ancient capital of Scotland
and the crowning place of kings


Replace @mailinator.com with @tiscali.co.uk


"Sarah" wrote in message
...
Hi....

Just wondering if anyone could help me with a formula or suggest how I may
do the following:

I have a list of contracts with dates from and to and would like to
calculate the number of months in each contract and which financial year
they
fall in (financial year running from 01/04 - 31/03) for example:

Contract A: 01/01/08 - 01/06/09 this will have 3months in 07/08 12 in
08/09
and 2 in 09/10.

Any help will be appreciated.

Thanks