Hi,
We have always worked out the time between 2 x date time fields and output them as 'Hours and Minutes' as below:
- string CalculateDuration(Date Start, Date End)
- {
- Duration = (((End - Start)) / (1000 * 3600)).toLong() + " Hour " + (((((End - Start)) / (1000 * 3600)).toDecimal() - (((End - Start)) / (1000 * 3600)).toLong()) * 60).toLong() + " Min";
- return Duration;
- }
The need has now arisen to calculate the Minutes and Seconds. I have tried many equations to no joy.
How would I do this please?
Regards