topic Convert time to integer in Building Power Apps
https://powerusers.microsoft.com/t5/Building-Power-Apps/Convert-time-to-integer/m-p/1579729#M405584
<P>Hey,</P><P>i'm working on a small Project and i'm kind of stuck on this particular point. I have a input box which returns a time value (normally written in the format hh:mm), and i want to convert this to an integer corresponding to a percentage of an hour bascially. For example, 00:30 would give 0.5, 01:15 would give 1.25 etc. I can't seem to find a way to do this.</P><P>The function that has this is called from a button, and for now contains this :</P><P> </P><P>evsInput.Text & " heure(s) à " & LookUp(typeEVS;TypeEVS = Dropdown1.SelectedText.Value;Coef) & " = " & 10*(evsInput.Text)*LookUp(typeEVS;TypeEVS = Dropdown1.SelectedText.Value;Coef)</P><P> </P><P>evsInput is my text input, and I just find the coefficient I need in my excel table, and then want to calcuate the pay rate for this amount of time. For now i'm just multplying the text input by 10 (base pay rate) and the coefficient.</P><P>I'd love any help you got <span class="lia-unicode-emoji" title=":slightly_smiling_face:">🙂</span></P>Wed, 11 May 2022 09:10:38 GMTlmszy2022-05-11T09:10:38ZConvert time to integer
https://powerusers.microsoft.com/t5/Building-Power-Apps/Convert-time-to-integer/m-p/1579729#M405584
<P>Hey,</P><P>i'm working on a small Project and i'm kind of stuck on this particular point. I have a input box which returns a time value (normally written in the format hh:mm), and i want to convert this to an integer corresponding to a percentage of an hour bascially. For example, 00:30 would give 0.5, 01:15 would give 1.25 etc. I can't seem to find a way to do this.</P><P>The function that has this is called from a button, and for now contains this :</P><P> </P><P>evsInput.Text & " heure(s) à " & LookUp(typeEVS;TypeEVS = Dropdown1.SelectedText.Value;Coef) & " = " & 10*(evsInput.Text)*LookUp(typeEVS;TypeEVS = Dropdown1.SelectedText.Value;Coef)</P><P> </P><P>evsInput is my text input, and I just find the coefficient I need in my excel table, and then want to calcuate the pay rate for this amount of time. For now i'm just multplying the text input by 10 (base pay rate) and the coefficient.</P><P>I'd love any help you got <span class="lia-unicode-emoji" title=":slightly_smiling_face:">🙂</span></P>Wed, 11 May 2022 09:10:38 GMThttps://powerusers.microsoft.com/t5/Building-Power-Apps/Convert-time-to-integer/m-p/1579729#M405584lmszy2022-05-11T09:10:38ZRe: Convert time to integer
https://powerusers.microsoft.com/t5/Building-Power-Apps/Convert-time-to-integer/m-p/1579745#M405588
<P>Ok well i just found how to do it, just have to convert minutes into hours (mm/60) and then add the hours and converted minutes.</P>Wed, 11 May 2022 09:19:07 GMThttps://powerusers.microsoft.com/t5/Building-Power-Apps/Convert-time-to-integer/m-p/1579745#M405588lmszy2022-05-11T09:19:07Z