Binary format reports to Ascii format reports...
Hi!
I have my reports in a database in a binary format.
What can I do to convert my reports to a ascii format? in code with out the
report designer.
I'm doing this (Note: I'm have Report Builder 7 and FIBPlus):
lReport.Template.DatabaseSettings.NameField := 'NAME';
lReport.Template.DatabaseSettings.TemplateField := 'TEMPLATE';
lReport.Template.DatabaseSettings.DataPipeline := plItems;
lReport.Template.DatabaseSettings.DataPipeline.Visible := False;
lReport.Template.SaveTo := stDatabase;
lReport.Template.DatabaseSettings.Name :=
dtstItems.FieldByName('NAME').AsString;
lReport.Template.LoadFromDatabase;
lReport.Template.Format := ftAscii;
lReport.Template.SaveToDatabase; {***} // In this line raise an exception
"DefaultFIBDataBase: Cannot perform operation - DB is not open".
{***}// but what
DB? my DB where my reports are stored is already connected.
Thanks!
I have my reports in a database in a binary format.
What can I do to convert my reports to a ascii format? in code with out the
report designer.
I'm doing this (Note: I'm have Report Builder 7 and FIBPlus):
lReport.Template.DatabaseSettings.NameField := 'NAME';
lReport.Template.DatabaseSettings.TemplateField := 'TEMPLATE';
lReport.Template.DatabaseSettings.DataPipeline := plItems;
lReport.Template.DatabaseSettings.DataPipeline.Visible := False;
lReport.Template.SaveTo := stDatabase;
lReport.Template.DatabaseSettings.Name :=
dtstItems.FieldByName('NAME').AsString;
lReport.Template.LoadFromDatabase;
lReport.Template.Format := ftAscii;
lReport.Template.SaveToDatabase; {***} // In this line raise an exception
"DefaultFIBDataBase: Cannot perform operation - DB is not open".
{***}// but what
DB? my DB where my reports are stored is already connected.
Thanks!
This discussion has been closed.
Comments
The exception you are receiving is not a ReportBuilder exception. Double
check to be sure the connection to your database is in fact open. You may
want to take a look at the following example of converting binary reports on
a database as text using the internal methods ReportBuilder uses...
http://www.digital-metaphors.com/tips/EditTemplatesAsText.zip
--
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com