Using a ClientDataSet I've added a calculated field and this works pretty well but only on the last record all previous calculated fields are recalculated and duplicated. I've tried redefining the field using the Fields Editor to InternalCalc but with the same results. How can I insure that values are only evaluated once?
Background:
DBGRID populated from ClientDataSet3 named (dataset3)
Sample Code:
with dataset3 do
Begin
append;
FieldByName('Persistent').AsString:=(var1);
FieldByName('Persistent2').AsString:=(var2);
FieldByName('Calculated').AsString:=(var3);
Post;
end;
procedure Tform1.Dataset3CalcFields(DataSet: TDataSet);
begin
dataset3.FindField('Calculated').AsString:=(Var3);
end;
I've tried to find more information from my reference material & Google but nothing directly addresses this behavior.
Thanks
Tony
Background:
DBGRID populated from ClientDataSet3 named (dataset3)
Sample Code:
with dataset3 do
Begin
append;
FieldByName('Persistent').AsString:=(var1);
FieldByName('Persistent2').AsString:=(var2);
FieldByName('Calculated').AsString:=(var3);
Post;
end;
procedure Tform1.Dataset3CalcFields(DataSet: TDataSet);
begin
dataset3.FindField('Calculated').AsString:=(Var3);
end;
I've tried to find more information from my reference material & Google but nothing directly addresses this behavior.
Thanks
Tony