Page 1 of 1

Function ELTime_sToString

Posted: 18 Nov 2008
by Januson
For some strange reason, I couldn't find any functions to convert Time_s to a formatted time hh:mm:ss

So I wrote one:

Code: Select all

[LegacyColorValue = true];

{ This function accepts an EL time and returns a formatted time string hh:mm:ss }
{ Functionname: ELTime_sToString }
{ Written by Januson Nov2008 }

inputs: TimeSelect( numericsimple );

var: timestr("");
timestr = RightStr("0" + NumToStr(TimeSelect,0), 6);


ELTime_sToString = LeftStr(timestr, 2) +
":" + MidStr(timestr, 3, 2) +
":" + RightStr(timestr, 2);

Posted: 20 Nov 2008
by brodnicki steven
Great function, Thanks !