Date Calculations

S

simoncohen

Cell A1 contains accounting Period start Date say 1/2/04
A2 contains accounting period end date say 31/1/5.

A3 contains a different start date say 1/4/04 and cell a4 contains
different end date say 31/3/05.

I need a formula to tell me how many of the days in 1/4/04-31/3/05 fal
within the accounting period.

Thanks in advance for your hel
 
B

Byers

try using the datevalue(date) function, it returns a number value and i
the two are subtracted, it should work out to the number of days.

so if you take the time frame and find out how many days are in it.
then do some wierd math to find out how many days are in there.
can't figure it out right now a little tired, and you might need som
if functions to account for different situations.

I feel your pain, dates are hard to deal with in excel cause o
different days in each month and leap years
 
A

acedia

I use NetworkDays. You can specify what days not to count
(i.e. weekends, holidays, or days not in accounting
period). Your date formats may need to be the same though.

you have to go to your add-ins and select the Analysis
Toolpak in order to use it.
I find it very useful!
search NetworkDays and it'll give you more insight and
examples.

i hope this helps. Unless someone has a better idea, this
will also work.

-Cede
 
Top