How to convert a timecode to seconds?

I would like to convert:
00:58:00

to

3480

(3480 is the seconds.)

So my goal is to get the value of the timecode converted to seconds , like it might be done on this webpage, instead of course calculated within KM. Scripts are ok, if necessary:

The start value: 00:58:00 is just an example......

In order to get this timecode, entered from the user (me), I used 3 variables:
variabler
Tim1
Min1
Sek1

(being norwegian that made sense).
Tim1 = Hours
Min1 = Minutes
Sek1 = Seconds

So how convert from 00:58:00 to 3480?

((Tim1 * 60) * 60) + (Min1 * 60) + Sek1

Or:

(Tim1 * 3600) + (Min1 * 60) + Sek1
1 Like

Thanks! That solved it nicely!