Home End User
New Blog Posts: Merging Reports - Part 1 and Part 2

Trying out IB Objects

edited June 2006 in End User
Have finally got IBO working now...if any of you guys get problems compiling
you need to get the source code (request permission from the authors) and
then you can get everything working...

Anyway now I need to RBuilder Help.

1. I am using the example provided to connect to a copy of my database that
reports were created using the BDE version of End User reports. When I try
to access one of the old reports I get the following...

"Class TdaBDEQueryDataView not found."

I can guess that this is becuase all the reports were created using the BDE
method. How do I resolve this..

2. DataDictionary. Using the example I can look at my dictionary and all of
the items in my dataabse are shown. However, when I run the Report Writer
the tables that come up when using the Query Builder do not refelect the
dictionary. All looks OK unless of course I have missed something. Any
advice

Cheers

Mark

Comments

  • edited June 2006
    As a follow up to this

    I adding a record to the RB_TABLE table manually and this shows up if I
    double click the Dictionary component but does not get displayed in the UI
    fornthe end user. Any pointers ?

    Cheers, Mark

  • edited June 2006
    OK

    One stage further...

    I loaded the demo BDE app and pointed to the same database...dictionary
    works fine for that so there seems to be an issue with the IBO demo?

    Cheers

    Mark


  • edited June 2006
    The following article explains how to convert templates from DADE plug-in
    type to another. The example is BDE to ADO, but the same concepts apply to
    any conversion.


    -------------------------------------------------
    Tech Tip: Convert BDE Template Dataviews To ADO
    -------------------------------------------------

    Currently when DADE is used to create dataviews, the DatabaseName is stored
    as part of the query definition. (This is consistent with Delphi's approach
    to specifying a database connection for a Query object).

    When you created the reports originally, the daDBBDE.pas BDE DADE plugin was
    used. Now you want to use ADO. You've already changed the
    Designer.Datasettings but this had no effect on the old reports. They still
    try to use the BDE connection. Changing the Designer.DAtaSettings only works
    for new dataviews that are created, because the new query dataviews are
    using the daADO.pas ADO DADE plugin.

    In order to convert the templates from BDE to ADO, at the minimum you have
    to change the database name and the DADE plugin class names that are stored
    in the templates. When a BDE dataview is created, its class type is a
    TdaBDEQueryDataview. When an ADO dataview is created, its class type is
    TdaADOQueryDataview. These class types are stored in the template. These
    have to be changed before the template is loaded into a report.

    First, compare a BDE report template to an ADO report template which both
    connect to the same database table. Save a BDE and an ADO based report
    template to separate ASCII text files. Now compare the dataview definitions.
    Change the TdaBDEQueryDataview class name to TdaADOQueryDataview in the BDE
    template. Change the BDE alias to your ADOConnection object. Then compare
    the table name and field names of the BDE template to the ADO template and
    change them accordingly, removing the .db extension on the table name is
    necessary. Now load the converted BDE template in your ADO end user
    application.

    The first step is to make a backup of all your templates before continuing
    with a programatic approach. You can convert the templates programatically
    by loading the ASCII template files to a TStringList object. Then loop
    through the lines of the list and change the text programatically. You can
    loop through the files in a directory using ppFileUtils.pas calling the
    GetFileNamesForDirectory procedure to load the file names.

    If you have binary report templates, you'll also be able to convert these
    with an extra couple of steps. You can load the binary template file into
    ASCII format, modify it, and then save it back to binary as shown in the
    example links below. Keep in mind the conversion is performed without
    loading the report template into a TppReport.


    This example shows how to load reports stored to the ReportExplorer database
    tables and convert them to ascii text.

    http://www.digital-metaphors.com/tips/EditTemplatesAsText.zip


    This example shows how to convert an .rtm file to asii text


    http://www.digital-metaphors.com/tips/ConvertBinaryTemplateToASCII.zip



    --
    Tech Support mailto:support@digital-metaphors.com
    Digital Metaphors http://www.digital-metaphors.com

    Best regards,

    Nard Moseley
    Digital Metaphors
    www.digital-metaphors.com
  • edited June 2006
    Nard

    Thanks for that I will review...any ideas about my Dictionary Problem?

    Mark

  • edited June 2006
    Nard

    The sample code in the zip file does not work so any assistance would be
    appreciated...

    Im using a Firebird database , D7 and RB 7 for reference

    Cheers

    Mark


  • edited June 2006
    Hi Mark,

    I downloaded the EditTemplatesAsText example and it seems to work correctly
    for me. This example is designed to only work with BDE and the built-in
    paradox tables included with ReportBuilder. You will need to alter the
    components and code on your own for it to work with your reports and/or
    database.

    I am unaware of any issues with IBO and the DataDictionary. I will download
    the latest version and see if I can recreate the issue you were seeing.

    --
    Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com

    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
  • edited June 2006
    Nico

    As you probably have worked out already I am not a full time developer and
    so struggle through some of this so thank you for putting up with me...

    I changed the components to point to my database, what else will I need to
    change to get this to work with an INterbase end user solution.

    Cheers

    Mark


  • edited June 2006
    Nico

    ANy luck with the data dictionary and IBO as yet?

    Thanks

    Mark
This discussion has been closed.