76
Views
2
Comments
Solved
Convert integer to time fails 
Question

Hi,


I am trying to convert integer into time format using FormatDateTime.

This is working as expected when the hour value is not 0 else the hour is taking default value 12.

For example :

FormatDateTime(AddSeconds(NewTime(0,0,0),104), "hh:mm:ss")

I am getting the value 12:01:44 (where hour defaults to 12 when there is no value) instead of 00:01:44.

How this issue can be resolved ?


Thanks and Regards,

Ramya Somashekaraiah

2020-03-04 14-50-24
Armando Gomes
Solution

Change hh:mm:ss to HH:mm:ss. That will fix it.

UserImage.jpg
Ramya Somashekaraiah

Armando Gomes wrote:

Change hh:mm:ss to HH:mm:ss. That will fix it.


Thank you. It works

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.