Internet PLC Forum
General => Technical support => Topic started by: Petty_boy on May 12, 2008, 02:54:41 AM
-
Hi, I would like to add a 24H six digit clock to my project, I have looked at the example in the usr directory but when the time is using single numbers i.e 7:9:4 it doesn't look very professional.
Ideally I would like a 24H clock that uses six digits to represent the time in the above example i.e. 07:09:04., or 19:09:04. I have tried adding some code to the above example by adding a "0" in front of the time[1] number if it is lower than 10 but I'm pulling my hair out trying to get it to work.....
Any assistance appreciated.
-
You can use:
STR$(TIME[1],2)+":"+STR$(TIME[2],2)+":"+STR$(TIME[3],2) to get fixed two digit display.
-
Hi Many thanks.