Home Subreports

Is it possible to have this kind of report?

edited October 2012 in Subreports

Hi

I need to print a invoice with master detail plus bank billing ticket.

I want to print like that

Header of company + invoice
Detail of invoice
Bank billing ticket at the end of page.

If Detail of invoice have a lot of itens, it will be print on next page.

I already get

Header with group
Detail with subreport
Group´s Footer

It´s work, but when subreport is longer, group´s footer is printed on
last group page and I would like to print at the end of first page.
Of course group´s footer isn´t right for that task and I am asking if
it is possible to have this kind of behavior.

Best regards

Sergio Melchiori


--

Comments

  • edited October 2012
    Hi Sergio,

    The group footer will always be printed at the end of a group.

    You can use the Footer band if you need information to print at the end
    of each page. If the footer band will not work for you, you can
    manually add drawcommands to the bottom of a page directly if needed.

    http://www.digital-metaphors.com/rbWiki/Delphi_Code/Formatting/How_To...Manually_Add_a_Watermark_to_a_Page

    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
  • edited October 2012
    Hi Nico

    I solve this problem using:

    group for invoice number

    group header - I put company logo and address, and other invoice
    information

    group detail band
    - I put a region and subreport inside region. Region is for
    displaying form line and covering text at the end of page (not first
    page).

    detail height = page height - group header height

    I put some information at the end of group detail band that will print
    only on first group page.

    At report event ONSTARTPAGE i put the code

    if ppreport1.pageno <= 1 then
    begin
    ppRegion1.minheight:= 190
    ppSubreport1.stopposition:= 190
    end
    else
    begin
    ppRegion1.minheight:= 258
    ppSubreport1.stopposition:= 258
    end;
    Page is A4 with 7 mm on all margins and group header height = 25 mm

    On first group page, at the end print billing information. If
    subreport goes to second page, at second group page, the subreport and
    region goes to the end off page, with no billing information.

    Best regards

    Sergio Melchiori





This discussion has been closed.