Hi,
I have a solution that is still in 2.2.7 that is having a problem.
I am trying to print out an invoice from my ‘orders’ table using a multiline portal for the related ‘line_items’ table.
This is going to be printed on some new pre-printed stationary with a peel off label for a bar code of the invoice number.
The form has 3 parts. The header has all the main invoice details (date, inv no, cust. details etc. The footer has totals & Page x of y. The body has the portal in it. I have set this to multi-line as I don’t want Servoy headers/grid and need precise object placement as the column headers (qty, item, desc., price etc.) are pre-printed.
The issue is that Servoy (Java?) seems to need a gap where the normal portal headers would be if you were not using multi-line. This only became apparent when printing invoices that were more than one page long. On the second page, the top line item was printed up higher than on the first page!
I have tried experimenting with all the properties of the portal to fix this (rowHeight etc.), but in the end I have had to move the portal down to allow the top line on all subsequent pages to appear beneath the printed headers, but it means that on the first page (and for most customers, ONLY page) the first line item is a big distance below the headers
I know there is the technique of printing from the line items file, but that is not an option here as my client does bulk invoice range printing (e.g. inv. no 712345…712896), so it would require a massive amount of work to re-jig the system to do it that way. I also have not tried using a tab panel after reading other posts implying they should not be used for things like this, where my portal is set to shrink or grow.
If anyone can offer an answer I & my client would be most grateful.
I think most of us don’t use portals, certainly not for printing and most certain not for printing with growing/shrinking parts.
At least if I am not mistaken
I would do this using a table view for the body part.
IT2Be:
I think most of us don’t use portals, certainly not for printing and most certain not for printing with growing/shrinking parts.
At least if I am not mistaken
I would do this using a table view for the body part.
Thanks for replying Marcel.
I just tried a Table view, but I think you must be doing that in the ‘child’, not the ‘parent’ as it didn’t help me
As I mentioned, I HAVE to do this from the ‘parent’ file, with the body displaying the ‘children’ (line items). A table view also would cause me problems as I need exact positioning & sizing of the related items so they show in the correct place on the new pre-printed invoice sheet.
I am attaching an image of my layout in case it helps anyone to help me.
Thanks.
If you have to do this in the parent record then perhaps you need to use HTML and a global text field set to HTML_AREA display type.
Hope this helps.
Hi,
I do HAVE to do it in parent. I’m not sure an HTML area would help me as if there are LOTS of lines on the invoice, I need Servoy to do all the hard work of creating a second (3rd, 4th…) page.
Thanks.
Well a HTML_AREA field can grow/shrink. You just need to query all the line items and display them using HTML.
Servoy will take care of the paging, although you might want to add a certain spacing in your HTML after x rows or so to make sure rows are not cut in 2.