Hello,
Probably a simple question, but I'm trying to calculate the number of days between two dates based on all years having 365 days (excluding +1 leap year days)
And I can't quite seem to figure it out
Thanks
Hello,
Probably a simple question, but I'm trying to calculate the number of days between two dates based on all years having 365 days (excluding +1 leap year days)
And I can't quite seem to figure it out
Thanks
Excel is smart enough to just let you subtract the dates with each other. So
# of days between date 1 & 2 = date 2 - date 1
Not so easy. Why don't you want to include leap days? That would be much simplier
ChemistB
My 2?
substitute commas with semi-colons if your region settings requires
Don't forget to mark threads as "Solved" (Edit First post>Advanced>Change Prefix)
If I helped, Don't forget to add to my reputation (click on the little star at bottom of this post)
Forum Rules: How to use code tags, mark a thread solved, and keep yourself out of trouble
While I "whole heartedly" agree with the question : Why do you want to exclude leap year days?
I just can't see any logical reason to do that..
but anyway, this will do it.
=SUMPRODUCT(--(TEXT(ROW(INDIRECT(A1&":"&A2)),"mmmdd")<>"Feb29"))-1
A1=Start Date
A2=End Date
Remove the -1 if Both Start and End Dates should be INCLUDED in the count.
Last edited by Jonmo1; 04-16-2013 at 12:49 PM.
Thanks Jonmo1, that did the trick. Sadly, I need to exclude leap year days because I'm trying to mimic an applications calculation for ARR that assumes all years at 365 days. And just subtracting one date from another doesn't do it.
Thanks again
Great, glad to help.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks