Customized invoice spanning over 4 (empty) pages 2013 R2

Miklos_HollenderMiklos_Hollender Member Posts: 1,598
edited 2014-10-10 in NAV Three Tier
I took R206, made the header about 2x as big by adding fields (the standard way, Claus's way did not want to risk yet), and added all kinds of texts under the VAT. It is not in the footer, just on the page directly under the lines. They are conditional, I mean their visibility is not, but it is conditional if Navision sends some data in them or not.

Now the invoice prints multiple empty pages after the meaningful pages. Usually 4, sometimes only 1 empty page. By empty I mean header only. When those text boxes are empty just 1, when there is data sent to them it prints every single one on a separate page.

This is really weird. What should I check? These are just basic textboxes thrown there, no complicated logic behind them.

Comments

  • TonyDuarteTonyDuarte Member Posts: 92
    I can say to check if any textbox have padding on it. It can disturb the output.

    Remove the "white" space so that your report fits your textboxes.

    Because that space at the bottom will be rendered and considered part of the report.

    Check the size of your report, if you are trying to output an A4 report and the size of the report is higher than the 21cm*29,7cm it will make the report print extra pages, keep in mind that if you have margins the horizontal size of the report will be 21 - left margin - right margin.

    For what i can see from the description and the image can be something like this.
  • Miklos_HollenderMiklos_Hollender Member Posts: 1,598
    Thank you, my size is the standard 21 * 29,7, what do you meam by removing white space, shoud I actually make the report smaller than the 29,7 cm, pull up the lower part so that it ends at the end of the last textbox?

    Or remove white space inside?

    No padding, thank you, check that.

    I am a little bit confused about the visual logic here. Unlike the Classic, in the new designer you need to put everything visually into an A4 size page in the editor itself, so even if you want, you could not put there like 3 pages long fixed text narratives or something. Yet, as Tablixes and other data-driven control expand, it does not end up being one A4, an invoice could 100 pages long. How to calculate with all this?
  • Miklos_HollenderMiklos_Hollender Member Posts: 1,598
    Is that normal that Preview says Page 1 of 1, print as PDF or actual printer Page 1 of 4, and it is indeed 4?

    One thing I was thinking that the issue may be that the standard list1_Contents rectangle is taking up the whole page, and maybe it is just printing this empty rectangle. But not, making tha smaller did not help, moving textboxes upward is at least reducing number of empty pages. Apparently, the part of the rectangle that is empty at the end is not rendered, but textboxes without data in them yes. Weird.



    I have no whitespace to remove now, the document now looks rather ugly, not sure the users will accept this, and still I have 1 empty page.

    Question: I shouldn't have stuff like 8 textboxes under each other, called FactoringText1,FactoringText2 etc. always use an integer table or similar data source and a Tablix?
  • TonyDuarteTonyDuarte Member Posts: 92


    Added my notes to see if it will help.

    And yes, if you have the print preview set to normal mode it can be different from what you get from the printer.

    To make it faster for you, open report in design -> go to properties -> previewmode and change it from Normal to PrintLayout.
    This way your preview will look as the printer.

    If the solution that I'm giving you in the image doesn't work at all, you will need to check if there is something wrong with your CopyLoop that can cause extra pages.

    Also you can mark the textboxes with diferent colors in order for you to sort what can cause the problem, I call it visual debug, it can take a few min but will help you a lot to sort it out.
  • Miklos_HollenderMiklos_Hollender Member Posts: 1,598
    First of all thank you, pulling the right edge left did it - apparently, if it is wider than the page, that part gets printed to extra pages, even when it is just whitespace.

    But before I set it solved I would like to understand it. I can pull the right side, also change the visual report width left, right, but the page size or similar properties do not change. So if these properties are set to e.g. 21 cm A4, I need to follow this with the visual width, and if yes, how, how do I measure that? There doesn't seem to be any property changing when I change this, so I cannot just compare or overwrite two numbers. Neither the other way around, I could not find a property I could write a number in and it would set the visual width to 21 cm.
  • TonyDuarteTonyDuarte Member Posts: 92
    In this case you could do a trick, that is using the textboxes that have their size of the all the horizontal length of the header.

    The problem consists in the following if you set the report to be A4 and Horizontal/Vertical it will only tell the printer the kind of paper and how to print.

    But what will count most is the area of the report, that's why that sugestion worked.

    Imagine like it was an excel sheet, and you can view the margins for print.

    If you ocupy another cell from the page next to the one you want to print and you didn't set the print area to your page
    you will print 2 pages, one with information and the other with that cell.

    The report will be something like that.
Sign In or Register to comment.