"Invalid floating point operation" when ShowReport
DeYo
Pozarevac, Serbia
I'm using Fast Report 2.5.3 and Delphi 7.
My problem: I have made Report (type Single). When I call Report from my program with frReport1.ShowReport for the first time it shows, but when I return to program and then try again I get the error message "Invalid floating point operation". Well, I need to have this work correctly becuse I need to enable more than one printnig in my program.
I have tried next
then I have tried not to use Show methods, so I have inserted frPreview component and connected it with frRaport.
same error.
then I have tried dinamically
only thing that worked (partially) was when I have set frReport's property StoreInDFM to true, to avoid extra loading (!?). Only line of code was: frReport1.ShowReport. Well, now Report was showed first time and second time, but on third attempt - same error.
Error was appearing no matter what was stored in frReport (DetailBands, OLE Objects, RichEdit...).
Any ideas???
My problem: I have made Report (type Single). When I call Report from my program with frReport1.ShowReport for the first time it shows, but when I return to program and then try again I get the error message "Invalid floating point operation". Well, I need to have this work correctly becuse I need to enable more than one printnig in my program.
I have tried next
frReport1.LoadFromFile('file_name');
frReport1.PrepareReport;
frReport1.ShowPreparedReport;
same error.then I have tried not to use Show methods, so I have inserted frPreview component and connected it with frRaport.
same error.
then I have tried dinamically
Form2:=TForm2.Create(Application)
report:=TfrReport.Create(Applicatio);
report.LoadFromFile('file_name');
report.Preview:=Form2.frPreview1;
report.PrepareReport;
report.ShowPreparedReport;
Form2.ShowModal;
Form2.Free;
report.Free;
same erroronly thing that worked (partially) was when I have set frReport's property StoreInDFM to true, to avoid extra loading (!?). Only line of code was: frReport1.ShowReport. Well, now Report was showed first time and second time, but on third attempt - same error.
Error was appearing no matter what was stored in frReport (DetailBands, OLE Objects, RichEdit...).
Any ideas???
Comments
What happens is that (for some reason) FastReport sometimes when saving Report sets first page's property Size to -1 (by default it's "A4 210 x 297 mm"). I don't why this happens but when I change the property back to default it all worked correctly.