I'm coding a program with Pascal in fastreport, The problem appear when I try to show the result of a division. this is my program:
var
relec_tp_for_pa, tp_for_pa, relec_tt_tp, total_tp, coef_relec : Real = 0;
relec_vt : Integer = 0;
procedure MasterData1OnBeforePrint(Sender: TfrxComponent);
begin
if ( ( <EJobsQuery."SERV_ID"> = 54 ) ) then
begin
relec_tp_for_pa := tp_for_pa;
relec_vt := relec_vt + <EJobsQuery."EJOB_VOLUME">;
relec_tt_tp := relec_tt_tp + tp;
total_tp := total_tp + tp;
end;
coef_relec := StrToFloat(FormatFloat('0.0000', relec_tt_tp / total_tp));
relec_pa.Text := FormatFloat('0.00', relec_vt /(relec_tp_for_pa * coef_relec));
relec_pr.Text := FloatToStr( relec_vt / relec_tt_tp );
end;
Both of this divisions:
-relec_vt /(relec_tp_for_pa * coef_relec)
-relec_vt / relec_tt_tp
are giving me the error : Invalid Floating point operation
I'm coding in the FastReport 4.11.4 a report. under 32 bits OS if this can help.
Thanks again.