Help - Search - Members - Calendar
Full Version: Changing DataSets
Fast Reports forum > Fast Reports Products > FastReport 4.0
Gecko
I have this setup:

FfrxDBDataset.DataSet := aDataSet // a TTable
FReport.DataSet := FfrxDBDataset;
FReport.DesignReport; // shows the table
FReport.ShowReport; // shows the table
// so far so good. Now:
FfrxDBDataset.DataSet := aDataSet // a TQuery with one record
FReport.DesignReport; // still shows the table!!
FReport.ShowReport; // still shows the table!!

How do I get the report to show the current contents of "aDataSet"?

TIA,
Jim
gordk
Can't be sure of what you are trying to explain.
the tfrxreportcomponents dataset property is ony used with multiple design page reports.
it controls the number of times a report is run.

usually your masterdataband's dataset property points to the frxdbdataset.
you can set the frxdbdatasets properties.
things can get very messy if you start changing datasets as the report design remebers the dataset used and its field names.
Gecko
Thanks.

I don't follow your last sentence: are you saying that even if I correct it to be, e.g.:

TfrxMasterData(FReport.FindObject('MasterData1')).DataSet := aDataSet

the report won't use the new records/fields in "aDataSet"?
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2012 Invision Power Services, Inc.