function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
iqbaliqbal 

Subtract Date/Time fields

Hi,

I created a formula field of type number which subtracts two date/time fields and i am getting strange result when two values are subtracted.

(12/24/2009 3:05 PM) - (12/24/2009 12:05 PM) is giving me 0.1250

I basically want to calculate difference between two date/time fields and i expect the difference to be in terms of 'days-months-hours-minutes'.

Has anyone faced this problem? If not with formula field, is there any other way to achieve this.?

 

thanks,

Asif

Steve :-/Steve :-/
The result that is being displayed is the difference in Days: 3 Hours = 0.125 Days.  What exactly do you want you formula to display? the time? just hours?  HH:MM?  HH:MM.SS?
iqbaliqbal
Thanks for your reply. HH:MM is good for me.