Uederson Ferreira Member Licensed User Mar 9, 2019 #1 Hi all! If I choose a time like "01:00" it returns minutes "0", and if I choose "01:05", it returns "5". I know it is because minute returns as int. I had a lot of work trying to solve it, but I think there is an easier way. Thank you in advanced! Uederson
Hi all! If I choose a time like "01:00" it returns minutes "0", and if I choose "01:05", it returns "5". I know it is because minute returns as int. I had a lot of work trying to solve it, but I think there is an easier way. Thank you in advanced! Uederson
DonManfred Expert Licensed User Longtime User Mar 9, 2019 #2 Do not expect any change in the lib. I do not have the source anymore. You need to write a small workaround-sub. Upvote 0
Do not expect any change in the lib. I do not have the source anymore. You need to write a small workaround-sub.
Uederson Ferreira Member Licensed User Mar 9, 2019 #3 Great! My workaround was (if it is usefull for someone else): Code: Sub time_onTimeSet (hour As Int, minute As Int, second As Int) If minute == 0 Then label.Text = hour &":00" Else If minute > 0 And minute < 10 Then label.Text = hour &":0"&minute Else label.Text = hour &":"&minute End If End Sub Thank you, friend! Upvote 0
Great! My workaround was (if it is usefull for someone else): Code: Sub time_onTimeSet (hour As Int, minute As Int, second As Int) If minute == 0 Then label.Text = hour &":00" Else If minute > 0 And minute < 10 Then label.Text = hour &":0"&minute Else label.Text = hour &":"&minute End If End Sub Thank you, friend!
udg Expert Licensed User Longtime User Mar 9, 2019 #4 Code: label.text = $"$2.0{hour}:$2.0{minute}"$ Upvote 0
GMan Well-Known Member Licensed User Longtime User Mar 9, 2019 #5 What is the "$" Character for ? Upvote 0