Delphi如何加载数据库中存储的报表

我正在尝试在Delphi中构建财务软件。对于数据库,我使用了Interbase,这是自从我以前使用Firebird以来第一次使用它。

Any way I am 80% done but I face a problem: I found that I can create a report with .fr3 (FastReport) inside the database - everything is Ok.

我没有找到任何解决方案,如何将存储的报告从数据库加载到项目中-类似于以下内容:

sReportFile := LoadFileFromDatabase ('ReportFiles', 'ReportFile', StrToInt(sID));

感谢您的指导。

评论
kqui
kqui

Assuming that the report is stored inside a bob field of one of the tables in the database, you can simply create a stream with TDataSet.CreateBlobStream and use that with TfrxReport.LoadFromStream.

点赞
评论