Código
procedure TForm1.Button1Click(Sender: TObject);
var
hr,min,hora,s : string;
begin
hr := floattostr(int(strtoint(edit1.Text)/60));
min := (floattostr((strtoint(edit1.Text)/60)-strtofloat(hr)));
min := floattostr(strtofloat(min) * 60);
min:= floattostr(int(strtofloat(FloatToStrF(strtofloat(min),ffnumber,10,2))));
FmtStr(s, '%.2d', [StrToInt(min)]);
hora := hr +':'+s;
edit1.Text:=hora;
end;
Planeta Delphi - www.planetadelphi.com.br - Todos os direitos reservados | Copyright 2001-2009