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

Blank. Empty Report

edited October 2003 in End User
We have a customer that created a report. When the report is displayed, the
report is totally blank (no titles, no headres, no column headings, no data,
no footers etc.) - just a blank page. There are no errors reported.

The datapipeline we use is JITPipeline. In addition, we are also using
DBISAM so the user has the ability to create data views on the Calc Tab
(which is what he is doing). The problem report does not not contain any
dbText pointing to the JITPipeline but rather all the dbText object point to
one DBISAM data view named 'reportdata'. The data view contains no data for
this particular report - the SQL returns no records.

For the same report where the data view does contain data - the SQL returns
records, the report displays fine.

I attempted to delete all the dbtext and variables objects from the
designer. Still the report was blank on the preview tab. Finally I switched
the report's data to the JITPipeline and the report did display (at least
the headers, column headings, and titles did).

The customer wants the headers to still display as well as the subtotals -
not a blank, empty page.

How do I avoid this issue? If a data view contains no data, the report
displas as blank. We have also seen issues where there may be 5 data views,
4 of them contain data, and the last one does not, and the report displays
as blank.

Thanks.

We are using RBP Ent 6.0.

Steve

Comments

  • edited October 2003

    Try using Report.NoDataBehaviors. See the RBuilder.hlp for info on this
    propery.

    --
    Nard Moseley
    Digital Metaphors
    http://www.digital-metaphors.com

    Best regards,

    Nard Moseley
    Digital Metaphors
    www.digital-metaphors.com
  • edited October 2003
    Reviewing a little more, the dbText objects are hooked up to fields that are
    setup as double type. Also, there are many instances in the on the Calc tab
    where the customer is attempting to load other variable objects based on the
    values returned in the dbCalc.

    For example:

    procedure RegRLPpOnCalc(var Value: Variant);
    begin
    Value := Reportdata['EthRLP']/ Reportdata['EthQty'];
    RegRLP := RegRLP + Reportdata['EthRLP'];
    end;

    Fields 'EthRLP' and 'EthQty' are double fields in the dataview. The dataview
    contains no data. So the problem, it appears, is RBP is expecting the data
    in the dataview for fields setup as double types to be 0 but they are
    returning as blanks.

    If I go to the Preview page and click the Next Page button, I receive an
    error "Could not convert variant of type (string) into type (double)".

    Is there anyway to check to see if reportdata has any data in it, if it
    doesn't handle it in each OnCalc procedure? Is there anyway to know if the
    value in the OnCalc procedure is a string? Finally, is there anyway in the
    SQL to put in a 0 if needed.

    To me, it seems the issue boils down that if a dataview's SQL results in no
    data, it should load 0's in the fields that are seutp as double. It is not
    doing this. Can this be done? If not, could you tell me what I need to do to
    handle if a double field in an empty data view is blank and not 0.

    Thanks.

    Steve
  • edited October 2003
    Thanks Nard.

    This seems to be what I want.
  • edited October 2003

    Try checking

    var
    lbNoData: Boolean;

    lbNoData := myPipeline.BOF and myPipeline.EOF;

    --
    Nard Moseley
    Digital Metaphors
    http://www.digital-metaphors.com

    Best regards,

    Nard Moseley
    Digital Metaphors
    www.digital-metaphors.com
This discussion has been closed.