ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   rounddown with date calc? (https://www.excelbanter.com/excel-discussion-misc-queries/63286-rounddown-date-calc.html)

Ltat42a

rounddown with date calc?
 

I'm trying to determine the number of years someone has on the job.
I'm using this formula - =DATEDIF(B7,TODAY(),"m")/12.

This gives me a result of 13.92, how can I round down this calculation
to 13.0?
If I remove the decimals...it rounds up to 14 - which is an error.

Thanx.


--
Ltat42a
------------------------------------------------------------------------
Ltat42a's Profile: http://www.excelforum.com/member.php...o&userid=24735
View this thread: http://www.excelforum.com/showthread...hreadid=498378


Bart Snel

rounddown with date calc?
 
Ltat42a schreef:
I'm trying to determine the number of years someone has on the job.
I'm using this formula - =DATEDIF(B7,TODAY(),"m")/12.

This gives me a result of 13.92, how can I round down this calculation
to 13.0?
If I remove the decimals...it rounds up to 14 - which is an error.

Thanx.


use ROUNDDOWN(cell;number of digits)

Bart Snel

RagDyer

rounddown with date calc?
 
Try this:

=FLOOR(DATEDIF(B7,TODAY(),"m")/12,1)
--
HTH,

RD
==============================================
Please keep all correspondence within the Group, so all may benefit!
==============================================



"Ltat42a" wrote in
message ...

I'm trying to determine the number of years someone has on the job.
I'm using this formula - =DATEDIF(B7,TODAY(),"m")/12.

This gives me a result of 13.92, how can I round down this calculation
to 13.0?
If I remove the decimals...it rounds up to 14 - which is an error.

Thanx.


--
Ltat42a
------------------------------------------------------------------------
Ltat42a's Profile:

http://www.excelforum.com/member.php...o&userid=24735
View this thread: http://www.excelforum.com/showthread...hreadid=498378



Peo Sjoblom

rounddown with date calc?
 
Why not using?

=DATEDIF(B7,TODAY(),"y")

for years

otherwise

=FLOOR(DATEDIF(B7,TODAY(),"m")/12,1)


--

Regards,

Peo Sjoblom



"Ltat42a" wrote in
message ...

I'm trying to determine the number of years someone has on the job.
I'm using this formula - =DATEDIF(B7,TODAY(),"m")/12.

This gives me a result of 13.92, how can I round down this calculation
to 13.0?
If I remove the decimals...it rounds up to 14 - which is an error.

Thanx.


--
Ltat42a
------------------------------------------------------------------------
Ltat42a's Profile:

http://www.excelforum.com/member.php...o&userid=24735
View this thread: http://www.excelforum.com/showthread...hreadid=498378




Ron Rosenfeld

rounddown with date calc?
 
On Thu, 5 Jan 2006 11:55:09 -0600, Ltat42a
wrote:


I'm trying to determine the number of years someone has on the job.
I'm using this formula - =DATEDIF(B7,TODAY(),"m")/12.

This gives me a result of 13.92, how can I round down this calculation
to 13.0?
If I remove the decimals...it rounds up to 14 - which is an error.

Thanx.


How about

=DATEDIF(B7,TODAY(),"y")


--ron

Ltat42a

rounddown with date calc?
 

I used both of these -
=DATEDIF(E5,TODAY(),"y")
and
=FLOOR(DATEDIF(B5,TODAY(),"m")/12,1)

They both work good. Thanx All!


Jim


--
Ltat42a
------------------------------------------------------------------------
Ltat42a's Profile: http://www.excelforum.com/member.php...o&userid=24735
View this thread: http://www.excelforum.com/showthread...hreadid=498378



All times are GMT +1. The time now is 08:43 PM.

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