Simple Time Duration Calculation

shawnFMU

11-10-2018

I need a simple Time Duration Calculation. What I've read and piece together, I can't seem to get it to work.

Time2Num and Num2Time...

Help!

In 1 day, Start time and End time equal how much Total time. Example 1:00 to 3:00 equal 2

I've set three Text Fields.

Time1

Time2

Total

Total text field, Calculate event, JavaScript

var start = Time2Num(Time1.formattedValue, "HH:MM")

var end = Time2Num(Time2.formattedValue, "HH:MM")

var dur = Num2Time(end + start, "HH:MM")

this.rawValue = dur;

Thank you in advance!

View Entire Topic