Only does HH:MM:SS format at the moment, but I can incorporate more formats into it.
Go easy on me.Code:function FormatTime(Time : Integer) : String; var Seconds, Minutes, Hours : Integer; StringTime : String; begin Seconds := Floor(Time / 1000); Hours := Floor(Seconds / 3600); Minutes := Floor((Seconds - Hours * 3600) / 60); Seconds := (Seconds - Hours * 3600) - Minutes * 60; if Hours < 10 then StringTime := '0' + IntToStr(Hours) + ':' else StringTime := IntToStr(Hours) + ':'; if Minutes < 10 then Insert('0' + IntToStr(Minutes) + ':', StringTime, Length(StringTime) + 1) else Insert(IntToStr(Minutes), StringTime, Length(StringTime) + 1); if Seconds < 10 then Insert('0' + IntToStr(Seconds) + '', StringTime, Length(StringTime) + 1) else Insert(IntToStr(Seconds), StringTime, Length(StringTime) + 1); Result := StringTime; end;I'm just trying to contribute.
![]()


I'm just trying to contribute.
Reply With Quote





