answersLogoWhite

0


Best Answer

-- If the earlier date is in A1 and the later date is in B1, then the number of days

between the dates is just [ = B1 - A1 ].

-- Format the cell with [ = B1 - A1 ] in it to display [ number / zero decimal places ].

-- Under [ File / Options / Advanced / ], find the choice on the big list there

that says "Display zero in cells with zero value" and check the box.

User Avatar

Wiki User

12y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: How do you calculate the number of days between two dates and return a 0 when cell is null?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

How do you calculate the number of days between two dates including weekends and bank holidays?

For Excel:Format A1 and A2 in the date format you prefer.Put your first date in A1 and your second date in A2.In A3, put the following formula: =A2-A1Observe the number of days between the two dates displayed in A3.


How do you get the answer to the question How many times did earth orbit the sun between 140ce and 1543?

-- Calculate the total number of years between those dates. -- That number will be reasonably close to the answer itself, since "orbit the sun" is just a more technical term for "year". A more accurate figure will involve the considerable tinkering with the calendar that went on during that period. The simple (140 + 1543) might not be accurate, but the first step given above still holds: Calculate the actual total number of years between those dates, and you'll have the number you're looking for.


How do you find the number of years weeks days between two dates you need this for calculating the amount of time from hire in date to todays date that an employee has been with the company?

Use excel. You need two cells with the dates in them (one with hire date, one with "=TODAY()" in it). Then to calculate the number of days (x), subtract one from the other. You can then create formulae to calculate number of years (=x/365), weeks (=x/7).


What are the release dates for Return to Sender - 2012 Between Dog and Wolf 1-5?

Return to Sender - 2012 Between Dog and Wolf 1-5 was released on: USA: 31 January 2012


Where can one find information about time calculator?

Information about a time calculator and what it is capable of doing can be found on the internet. Time calculators work strictly with dates and times to calculate total time or to calculate the difference between dates and times.


Calculate the number of days from March 3 2009 to May 12 2010?

There are 436 days, inclusive of the dates given.


How do you calculate number of days between two dates?

Put the two dates into separate cells. Say you put the earlier one in cell A1 and the later one in cell A2. Then in cell A3 you could put the formula: =A2-A1 This will initially give you a date. Then you would format the cell as a number, using the Format menu and the Cells option and the Number option. Alternatively you could click on the comma icon on the formatting toolbar. The number that is displayed will be the difference in days between the two dates. Another way to do it is with the Datedif Function. =DATEDIF(Date1, Date2, Interval) Where: Date1 is the first date. Date2 is the second date. Interval is the interval type to return. If Date1 is later than Date2, DATEDIF will return a #NUM! error. If either Date1 or Date2 is not a valid date, DATEDIF will return a #VALUE error. The Interval value should be one of "d", "m", "y", "ym", "yd" or "md". These will give you the result in days, months, years, months excluding years, days excluding years and days excluding years and months. For the earlier example you could do it like this: =DATEDIF(A1,A2,"d")


What are the release dates for The Return - 2014?

The Return - 2014 was released on: USA: 2014


How do you compute the difference in days between two dates formatted as yyyy-mm-dd in PHP?

== == function dayDiff($date1, $date2) { if($date1 < $date 2) { $dateStart = $date1; $dateEnd = $date2; } else { $dateStart = $date2; $dateEnd = $date1; } $date1Timestamp = strtotime($dateStart ); $date2Timestamp = strtotime($dateEnd ); $dayDiff = ($date2Timestamp - $date1Timestamp)/(60*60*24); return $dayDiff; } No matter in which format dates are formatted. /** * Returns the number of days between two PHP dates */ function days_between($d1, $d2){ if($d1 >= $d2){ $dd1 = $d2; $dd2 = $d1; } else{ $dd1 = $d1; $dd2 = $d2; } return floor(($dd2 - $dd1) / 86400); } /** * Converts an ISO 8601 YYYY-MM-DD date to a PHP date */ function iso_date_to_timestamp($dt){ list($y, $m, $d) = explode("-", $dt, 3); if(is_numeric($y) && is_numeric($m) && is_numeric($d)){ return mktime(0, 0, 0, intval($m), intval($d), intval($y)); } else{ return 0; } } /** * Returns the number of days between two dates expressed as ISO8601 * style YYYY-MM-DD dates */ function days_between_iso($d1, $d2){ return days_between(iso_date_to_timestamp($d1), iso_date_to_timestamp($d2)); }


How do you find out days and month calculation in Excel?

Arithmetic works with dates and displays the results as days, so just multiply the result times 24 to get the approximate number of hours between the dates (Excel default format for dates assumes each day has a full 24 hours). If your oldest date is in A1 and your most recent date is in A2, use the following formula to calculate hours between the two dates: =(A2-A1)*24.If you need to show exact hours between specific times for two dates, just format A1 and A2 to display both date and time (a standard option under cell format for dates SAMPLE: 1/1/09 12:00 AM).


How old is a boosey and hawkes trumpet no 609972?

Your serial number dates it to between 1976 and 1977.


What are the release dates for Rachel's Return - 2014?

Rachel's Return - 2014 was released on: USA: 2014