I have taken a variable say temp of duration where value are calculated as temp:=(to time-from time).to time and from time both are of time data type.If result is coming as 3 hrs 29 min 50 sec
then i want it to be displayed as 3.49 hrs
How i can do it
Please help me
0
Comments
You can do this by using an int variable for subtracting time. If you have variables time1 and time2 of TIME type then the rezult of (time2 - time1) will be expressed in milliseconds. So, in order to achieve what you want - to express the rezult in hours - you have to divide the integer by 1000 * 60 * 60.
Exemple:
Name DataType Subtype Length
Time1 Time
Time2 Time
Int Integer
I hope this will help you.