Converting database reports to .rtm files
Dear Mr, Mrs,
I am trying to convert the reports that are stored in my table as blob
fields to .rtm files. But I get a errormessage: ETemplateSaveError; Cannot
store a template to a field of this type.
Anyone has a idea what I'am doing wrong?
I am using the following code:
Dm.ppDesigner.Report := Dm.ppReport; //Connects the designer to the
report.
with Dm.ppDesigner do
begin
with Dm.ppReport do
begin
//DataPipeline, Name, NameField, and TemplateField properties.
Template.DatabaseSettings.DataPipeline := Dm.ppReportTool;
Template.DatabaseSettings.NameField := 'Description';
Template.DatabaseSettings.Name := ReportName;
Template.DatabaseSettings.TemplateField:= 'ReportFile';
Template.LoadFromDatabase;
//Report loaded from database, let's save it to a RTM file.
Template.DatabaseSettings.DataPipeline := Nil;
Template.DatabaseSettings.NameField := '';
Template.DatabaseSettings.TemplateField:= '';
Template.FileName := 'c:\test\test.rtm';
Template.SaveToFile;
end; //with Dm.ppReport
end;
I am trying to convert the reports that are stored in my table as blob
fields to .rtm files. But I get a errormessage: ETemplateSaveError; Cannot
store a template to a field of this type.
Anyone has a idea what I'am doing wrong?
I am using the following code:
Dm.ppDesigner.Report := Dm.ppReport; //Connects the designer to the
report.
with Dm.ppDesigner do
begin
with Dm.ppReport do
begin
//DataPipeline, Name, NameField, and TemplateField properties.
Template.DatabaseSettings.DataPipeline := Dm.ppReportTool;
Template.DatabaseSettings.NameField := 'Description';
Template.DatabaseSettings.Name := ReportName;
Template.DatabaseSettings.TemplateField:= 'ReportFile';
Template.LoadFromDatabase;
//Report loaded from database, let's save it to a RTM file.
Template.DatabaseSettings.DataPipeline := Nil;
Template.DatabaseSettings.NameField := '';
Template.DatabaseSettings.TemplateField:= '';
Template.FileName := 'c:\test\test.rtm';
Template.SaveToFile;
end; //with Dm.ppReport
end;
This discussion has been closed.
Comments
I got rtm files, but I seem to have lost all my detailed information like
pipelines etc. Maybe I have missed something? A property that I need to set?
Please reply,
Best regards,
Mischa E.J. Hoogendoorn
when the report template file is loaded. What are the datasettings in the
database configuration when you are running the tempaltes from teh end user
designer? These settings will need to be available for hte file based
templates in the same way they are needed for the end user database
templates.
Cheers,
Jim Bennett
Digital Metaphors
http://www.digital-metaphors.com
info@digital-metaphors.com