Delphi-PRAXiS

Delphi-PRAXiS (https://www.delphipraxis.net/forum.php)
-   Sonstige Fragen zu Delphi (https://www.delphipraxis.net/19-sonstige-fragen-zu-delphi/)
-   -   Overflow in conversion or arithmetic operation (https://www.delphipraxis.net/42389-overflow-conversion-arithmetic-operation.html)

junale 18. Mär 2005 10:04


Overflow in conversion or arithmetic operation
 
Hallo,

wie kann ich folgenden Fehler umgehen...

Delphi-Quellcode:
if (fValInt64 >= -2147483648) and (fValInt64 <= 2147483647) then begin
...
end;
erzeugt:

Zitat:

Compiler Errors: Delphi
Overflow in conversion or arithmetic operation
The compiler has detected an overflow in an arithmetic expression: the result of the expression is too large to be represented in 32 bits.
Check your computations to ensure that the value can be represented by the computer hardware.
Laut Borland ist dieses Problem closed. Ich habe aber nicht vor, mir deswegen eine neue Delphi Variante zu kaufen.

Kennt jemand ein Workaraound/Patch?

Danke,
Alex

junale 18. Mär 2005 10:13

*SORRY* hab schon was gefunden....
 
Ich war zu ungeduldig.... habe soeben eine Lösung gefunden...

Delphi-Quellcode:
  if (fValInt64 >= Integer($80000000)) and (fValInt64 <= 2147483647) then ...
Sorry für diesen unnötigen Post - aber vielleicht interessierts ja noch einige Delphi 7 Nutzer!

mfg,
Alex


Alle Zeitangaben in WEZ +1. Es ist jetzt 04:06 Uhr.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024 by Thomas Breitkreuz