calculate day for day
I need a formula to calculate day for day for a 365 year. The only function
I can find in excel is days360. For example: If I took a vacation from 1 mar 04 thru 10 mar 04 that would be 10 days. Which I can do with SUM +1 but if the cells are blank I need the amount of days to be zero (or blank) not 1. |
Hi
Try something like this: =((C8-C7)+AND(C70,C80))*(AND(C70,C80)) -- Andy. "AG" wrote in message ... I need a formula to calculate day for day for a 365 year. The only function I can find in excel is days360. For example: If I took a vacation from 1 mar 04 thru 10 mar 04 that would be 10 days. Which I can do with SUM +1 but if the cells are blank I need the amount of days to be zero (or blank) not 1. |
First of all, no need to use days360, it's an obscure function for accountants,
nor do you need sum, you can just subtract, i.e. A1 holds start date and B1 end date =IF(OR(A1="",B1=""),0,B1-A1+1) will take care of blank days as well format as general you might also want to look at the networkdays function, it is part of ATP and comes with excel/office, it will count workdays only Regards, Peo Sjoblom "AG" wrote: I need a formula to calculate day for day for a 365 year. The only function I can find in excel is days360. For example: If I took a vacation from 1 mar 04 thru 10 mar 04 that would be 10 days. Which I can do with SUM +1 but if the cells are blank I need the amount of days to be zero (or blank) not 1. |
Thanks!
"Peo Sjoblom" wrote: First of all, no need to use days360, it's an obscure function for accountants, nor do you need sum, you can just subtract, i.e. A1 holds start date and B1 end date =IF(OR(A1="",B1=""),0,B1-A1+1) will take care of blank days as well format as general you might also want to look at the networkdays function, it is part of ATP and comes with excel/office, it will count workdays only Regards, Peo Sjoblom "AG" wrote: I need a formula to calculate day for day for a 365 year. The only function I can find in excel is days360. For example: If I took a vacation from 1 mar 04 thru 10 mar 04 that would be 10 days. Which I can do with SUM +1 but if the cells are blank I need the amount of days to be zero (or blank) not 1. |
All times are GMT +1. The time now is 05:38 AM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com