ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   =today()-3/7/2009 = 4? (https://www.excelbanter.com/excel-worksheet-functions/236451-%3Dtoday-3-7-2009-%3D-4-a.html)

dindigul

=today()-3/7/2009 = 4?
 
As given above, I tried the function I get 4 when I use custom cell format
as "d", whereas if I don't specify "d" it shows 125. What am I doing wrong?
Thanks



Eduardo

=today()-3/7/2009 = 4?
 
Hi,
have the formula =today() in one cell (A1), let's say that you have the
other date in cell A2, in B2 enter

=A1-A2
format column B as number no decimals

"dindigul" wrote:

As given above, I tried the function I get 4 when I use custom cell format
as "d", whereas if I don't specify "d" it shows 125. What am I doing wrong?
Thanks




Niek Otten

=today()-3/7/2009 = 4?
 
The difference between those two dates is indeed 125 days. The number 125 as
a date means Thursday, May 03, 1900. Thursday is the 4th day, that's why you
get 4 if you format as d.
What result did you want?


--
Kind regards,

Niek Otten
Microsoft MVP - Excel

"dindigul" wrote in message
...
As given above, I tried the function I get 4 when I use custom cell format
as "d", whereas if I don't specify "d" it shows 125. What am I doing
wrong?
Thanks





All times are GMT +1. The time now is 03:36 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com