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

Printing a subreport for a single row

edited January 2005 in General
I have a report that consists of two subreports. I need to print the
subreports for the current row in the dataset only. I do not want to
traverse all of the rows. How can I do this with PrintBehavior set to
pbSection.

--
Bill Todd

Comments

  • edited January 2005
    Hi Bill,

    I'm a bit unclear about the effect you are after. If you do not want
    ReportBuilder to traverse your data, you could simply disconnect the
    datapipeline from your report and access the current record directly from
    the DetailBand.BeforePrint event perhaps.

    --
    Regards,

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

    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
  • edited January 2005
    Hi Nico,

    Sorry but I do not understand what you mean by "disconnect the
    datapipeline from your report and access the current record directly from
    the DetailBand.BeforePrint event". If I disconnect the datapipeline how
    can the report get data from the current record?

    The effect that I am trying to get is to start at the first record in a
    dataset, print the report for that record, move to the next record, print
    the report for that record and so on. This sounds silly but there really
    is a purpose. The report generated by each record is several pages long.
    The reports are being printed on a printer with a built-in stapler. The
    printer staples at the end of each print job. Therefore, I must print the
    data for each row as a separate print job so they will be stapled
    individually.

    If I must I can filter the dataset on the primary key but I was hoping for
    a simpler solution. Any suggestion would be welcome.

    --
    Bill Todd

  • edited January 2005
    Hi Bill,

    You may simply be able to set the print count of the detail band in the
    section style subreport to 1. Take a look at the following example and see
    if that will work for you. If not, you may need to filter your dataset
    manually in order to print a single record per subreport.

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

    --
    Regards,

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

    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
This discussion has been closed.