TFrxDBDataset change Dataset at runtime?
Hello,
How do I change the Dataset / Datasource Value of a TFrxDBDataset at runtime so that the report gets to know the change.
I want to concentrate all the printing of my App in one place (a Datamodule). All the reports I have to print use 3 Datasets at most.
So I put 3 TDatasets on the Module and 3 frxDBDatasets.
If I show or print a report, whose datasets have been set up at designtime with these Components, all works fine.
If I change the SQL query of the underlying Dataset(s) in my code, the report remains empty.
As I understand, the TfrxReport Component provides the Dataset (and thus the content) to the Report to print.
The Report (.fr3) stores these "connection" to the given Dataset and the data.
If I try to edit a report (.fr3) that is not designed with the actual TfrxReport / Dataset combination, I need to set up the appropriate Combination of Dataset(s) to the Tfrxreport Component
tp make it work.
Is there a Parameter (or more) to set to have the TFrxReport refresh its data after changing the Dataset value?
Do I have to put a TDataset / frxDBDataset combination on the Module for all possible Queries of the reports I want to print?
TIA Rolf
How do I change the Dataset / Datasource Value of a TFrxDBDataset at runtime so that the report gets to know the change.
I want to concentrate all the printing of my App in one place (a Datamodule). All the reports I have to print use 3 Datasets at most.
So I put 3 TDatasets on the Module and 3 frxDBDatasets.
If I show or print a report, whose datasets have been set up at designtime with these Components, all works fine.
If I change the SQL query of the underlying Dataset(s) in my code, the report remains empty.
As I understand, the TfrxReport Component provides the Dataset (and thus the content) to the Report to print.
The Report (.fr3) stores these "connection" to the given Dataset and the data.
If I try to edit a report (.fr3) that is not designed with the actual TfrxReport / Dataset combination, I need to set up the appropriate Combination of Dataset(s) to the Tfrxreport Component
tp make it work.
Is there a Parameter (or more) to set to have the TFrxReport refresh its data after changing the Dataset value?
Do I have to put a TDataset / frxDBDataset combination on the Module for all possible Queries of the reports I want to print?
TIA Rolf