![]() |
![]() |
![]() |
![]() |
![]() |
FTP | ![]() |
![]() |
CCD | ![]() |
![]() |
Buscar | ![]() |
![]() |
Trucos | ![]() |
![]() |
Trabajo | ![]() |
![]() |
Foros | ![]() |
#1
|
|||
|
|||
Error en UDF
Hola a todos:
Disculpen el primer mensaje, no conocía los formatos. Trabajo con Delphi 7 y Firebird 1.5. He creado la siguiente función en una UDF: Código:
function SecsToFmt(secs: Integer): PChar; cdecl; export; var hh,mm: Integer; begin try hh := Trunc(secs/3600); secs := secs Mod 3600; mm := Trunc(secs/60); secs := secs Mod 60; Result := PChar(Format('%.2d:%.2d:%.2d',[hh,mm,secs])); except Result := PChar(Format('%d',[secs])); end; end; select secstofmt(140) from .... Me sale el error: arithmetic overflow or division by zero has occurred. arithmetic exception, numeric overflow,or string truncation Alguien me puede decir que esta mal? Gracias. |
#2
|
||||
|
||||
Hola,
Cita:
Saludos y bienvenido a estos foros. |
![]() |
|
|
![]() |
|