Auto counting

  • Thread starter Thread starter ernie
  • Start date Start date
E

ernie

I got dates under column A and days passed by since date in column A in
Column B. How do I ask it to auto calculate the days passed with reference to
the date in real time.

Example:

A B
5 march 2010 11days
10 march 2010 6days

Given today's date is 17 march 2010
 
Try

=SUMPRODUCT(INT((TODAY()-A1+WEEKDAY(A1-{2,3,4,5,6}))/7))

OR (From Analysis Tool Pak Add-In)
=NETWORKDAYS(A1,TODAY())
 
okay! thanks. I got exactly what I want. But I'm really interested to know
how it works.. Can you explains to me ? Please. Thanks you.
 
The array gives the day numbers for the days Monday through Friday. For
example if you want to get a count of weekend days change that to {1,7}

You could re-write the formula as below...which will only consider the
weekdays which are specified in the array
=SUMPRODUCT(--(WEEKDAY(ROW(INDIRECT(A1&":"&TODAY())))={2,3,4,5,6}))
 
Back
Top