Código
function SegundosToTime( Segundos : Cardinal ) : String;
var
Seg, Min, Hora: Cardinal;
begin
Hora := Segundos div 3600;
Seg := Segundos mod 3600;
Min := Seg div 60;
Seg := Seg mod 60;
Result := FormatFloat(',00', Hora) + ':' +
FormatFloat('00', Min) + ':' +
FormatFloat('00', Seg);
end;
Exemplo de uso:
ShowMessage( SegundosToTime(87543) );
Planeta Delphi - www.planetadelphi.com.br - Todos os direitos reservados | Copyright 2001-2009