Einzelnen Beitrag anzeigen

Benutzerbild von Bummi
Bummi

Registriert seit: 15. Jun 2010
Ort: Augsburg Bayern Süddeutschland
3.470 Beiträge
 
Delphi XE3 Enterprise
 
#8

AW: calculating Rows in Table

  Alt 11. Aug 2012, 17:53
Zitat:
tpRunTotal := FloatToStr((StrToFloat(tpRunTotal) + (StrToFloat(Table.FieldByName(field).AsString))));
uargh ...... whats that ....
Query with SUM as described is the better solution, but if you want to use something like that, then use a double or currency for tpRunTotal and convert it after the loop ...
Thomas Wassermann H₂♂
Das Problem steckt meistens zwischen den Ohren
DRY DRY KISS
H₂ (wenn bei meinen Snipplets nichts anderes angegeben ist Lizenz: WTFPL)
  Mit Zitat antworten Zitat