Hours to minutes conversion required

I subtracted 2 values.

Q: last 4 of (“0000” & ((it / 60) as string & last 2 of (“00” & ((it mod 60) as string))) of ((((substring (0,2) of it) as Integer * 60 + ((substring (2,2) of it) as Integer)) of (value “WindowEnd” of key “HKEY_LOCAL_MACHINE\SOFTWARE\CRQ\Maintenance\Reboot” of native registry as string)) as integer - (((substring (0,2) of it) as Integer * 60 + ((substring (2,2) of it) as Integer)) of (value “WindowStart” of key “HKEY_LOCAL_MACHINE\SOFTWARE\CRQ\Maintenance\Reboot” of native registry as string)) as integer))
A: 0130
T: 669

Here 01 is Hour and 30 is minutes .

This above values , I am passing to another tool as input.

However that tool is not able to understand hour input . It expecting me to convert all the values in minutes format.

meaning instead of 1 hour 30 mins , I need 90 minutes in total.

Can you please assist me here . Thanks.

I think that you already solved this problem here: Subtraction of two strings - #3 by goperiya1

It suppose to give me result as 1 hour , 10 mins. But I am getting as 70 mins.

Hello goperiya1,

Please try the following relevance:

q: 60 * integer (preceding text of position 2 of "0130") + integer (following text of position 2 of "0130")
A: 90

Be careful about the position index: if 0130 is integer, the first 0 won’t be counted.

Regards,
Vitaliy

Hi Vitaliy,

Actually along with script , I need convert the values . I mean , using the below one , I need convert .

last 4 of (“0000” & ((it / 60) as string & last 2 of (“00” & ((it mod 60) as string))) of ((((substring (0,2) of it) as Integer * 60 + ((substring (2,2) of it) as Integer)) of (value “WindowEnd” of key “HKEY_LOCAL_MACHINE\SOFTWARE\CRQ\Maintenance\Reboot” of native registry as string)) as integer - (((substring (0,2) of it) as Integer * 60 + ((substring (2,2) of it) as Integer)) of (value “WindowStart” of key “HKEY_LOCAL_MACHINE\SOFTWARE\CRQ\Maintenance\Reboot” of native registry as string)) as integer))

Yes. Even trying to connect with TIM . Thought he is not available today and raised new question in forum .