Need Help Doing time based calculations

Use the Set Variable to Text %CurrentClipboard% action to copy the value into a variable.

Use the Search Variable action for (\d+):(\d+):(\d+.\d+) to break the time apart into Hours, Minutes, Seconds.

Use the Set Variable Time to Calculation Hours * 3600 + Minutes * 60 + Seconds to get a time in seconds.

Use the Set Variable Time to Calculation to do your arithmetic.

Use Set Variable Hours to Calculation TRUNC( Time/3600 ) - format as 00

Use Set Variable Minutes to Calculation TRUNC( (Time - 3600*Hours)60 ) - format as 00

Use Set Variable Seconds to Calculation Time - 3600Hours - 60Minutes - format as 00.000

Then Set Clipboard to Text %Variable%Hours%:%Variable%Minutes%:%Variable% Seconds%

Something like that should do the trick.

4 Likes