Update dataset while traversing in report
Hi
how can I update a field when report is traversing dataset?
procedure TForm40.frxDBDataset1Next(Sender: TObject);
begin
frxReport1.Edit;
frxReport1.FieldByName('printdate').AsDateTime:= Date;
frxReport1.Post;
end;
Thanks
Sergio Melchiori
how can I update a field when report is traversing dataset?
procedure TForm40.frxDBDataset1Next(Sender: TObject);
begin
frxReport1.Edit;
frxReport1.FieldByName('printdate').AsDateTime:= Date;
frxReport1.Post;
end;
Thanks
Sergio Melchiori
Comments
If you really want to update the data directly in the dataset as the report is printing, you need to use the even of the dataset linked to your TfrxDBDataSet. Be careful, if your report is using the DoublePass... you might end up updating your data twice.