Home General
New Blog Posts: Merging Reports - Part 1 and Part 2

Calculated Field value

edited June 2002 in General
Good Morning!

Delphi 4, Firebird 1, Rb Pro 6.03 eval.

I have some xQuery (TxQuery, a shareware component that can read the
TkbmMemTable dataset) fields of FieldKind = fkCalculated. When I try to put
the calculated value (float, string or integer) (in the OnCalcFields event)
I can see that the actual value is correct but the xQueryField10.Asfloat :=
xQueryField2.Asinteger * xQueryField3.AsFloat ends up with a value of zero
or null. The same thing happens with strings. Then that field prints
nothing.

Any ideas?

Thanks...Dan'l

Comments

  • edited June 2002
    RB simply grabs values out of the pipeline field when the report is
    traversed. The problem seems to be happening at the actual calculationm, in
    OnCalcFields. Try debugging the calculation to see if a valid value is
    actually being put into xQueryFields10. Drop a DBGrid on the form and check
    the data before it is actually piped into the report to make sure the
    calculated fields is being computed properly in the first place.

    --
    Cheers,

    Alexander Kramnik
    Digital Metaphors

This discussion has been closed.