Open a default template when new report in explorer
Hi, Nico,
I managed to register my own Report Explorer Dialog and I change the File|
New menu
option handler code to:
if( trvFolders.Selected <> nil) then
liFolderId := Integer(trvFolders.Selected.Data)
else
liFolderId := itAllFolders;
FReportExplorer.Designer.Report.Template.FileName:='C:\SINCHOR\rep1origin.rt
m';
FReportExplorer.Designer.Report.Template.LoadFromFile;
FReportExplorer.CurrentFolderId:=liFolderID;
FReportExplorer.Designer.ShowModal;
So, it does load the template when new report. But when I want to save the
report, it always
save to my last opened report instead of prompt me a save dialog to save the
report.
How should I do to indicate the Report explorer than I am actually add a new
report??
Rgds
Vincent
Dialog
Developer's
I managed to register my own Report Explorer Dialog and I change the File|
New menu
option handler code to:
if( trvFolders.Selected <> nil) then
liFolderId := Integer(trvFolders.Selected.Data)
else
liFolderId := itAllFolders;
FReportExplorer.Designer.Report.Template.FileName:='C:\SINCHOR\rep1origin.rt
m';
FReportExplorer.Designer.Report.Template.LoadFromFile;
FReportExplorer.CurrentFolderId:=liFolderID;
FReportExplorer.Designer.ShowModal;
So, it does load the template when new report. But when I want to save the
report, it always
save to my last opened report instead of prompt me a save dialog to save the
report.
How should I do to indicate the Report explorer than I am actually add a new
report??
Rgds
Vincent
Dialog
Developer's
This discussion has been closed.
Comments
Since you are loading this template from file before showing the report
explorer, you will need to use the Save As option to save the report as a
new file. Save, by default will save the report to the template file
already opened.
--
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com