Jump to content
Sign in to follow this  
Quartekoen

Purposely causing extra portal rows to appear

Recommended Posts

I have an invoice database that lists all items in a portal, and is designed to print them. The portal is 32 rows, which it prints. A script then rolls the portal down to show the next 32 rows, and print them as well, until it nears the end. When the script realizes that it won't be able to scroll another 32 rows, it simply goes to the end.

My problem is that, for an invoice, I can't be printing the same data twice. This occurs at the end, when the portal only scrolls, say, 17 rows. The 15 rows above that would appear on this page, as well as the one I printed last. I'm wondering, is there any way to purposely get FM to dynamically show more empty rows at the bottom, so that the portal scrolls past data that has already been printed? Thanks

-Quartekoen

Share this post


Link to post
Share on other sites

Well, with some clever scripting and a little work, I've gotten that sort of result, but after some testing, I found something much more problematic: scrolling portals don't print any scrolling you've done! Does anyone know of a way to get a portal to print after being scrolled?

Share this post


Link to post
Share on other sites

Printing from Invoice forms with portals of LineItems works very well *if* you restrict the portal relationship by the number of records-to-portal rows ( via script ). This is particularly helpful when you must print onto forms such as HCFA-1500 which requires sub-totals per PAGE. Your totals would easily be based upon the filtered relationship itself. You know how many 'forms' are required by dividing the total number of records by the number of portal rows ( and if Mod(), + 1 ) no problem with scrolling at all.

Forms such as HCFA-1500 require 'totals' at the end of every page. It is no different than printing from LineItems and restricing the found set to produce the same form total.

LaRetta

Edited by Guest

Share this post


Link to post
Share on other sites

Well, that sounds like it would do exactly what I need. Would you mind giving me some tips on how to make this script that restricts the relationship? Thanks.

Share this post


Link to post
Share on other sites

Why not print directly from a list view of the items table?

Simply because the invoice is an actual invoice given to customers, and it requires a certain layout with the listing of items they ordered, as well as other information.

Edited by Guest

Share this post


Link to post
Share on other sites

A list view ( from LineItems ) should give you what you wish and is standard way it is done unless you have two specific needs: 1) You need sub-totals per page and 2) you have details which need to display along the left or right gutter which you can't have repeated on each row ( meaning you need a form ). With list view ( from LineItems ), you can place anything in leading part ( including Invoice detail fields directly from Invoice table ). And it will be faster as well.

I am happy to provide example if you really need it but it will be tonight before I will have the time.

Share this post


Link to post
Share on other sites

Okay, I have a list view working, and looking at the preview, it's doing what I need! There's only one more thing. While I do not need subtotals at the end of each page, I do need a grand total on only the last page. Is this possible? Thanks.

Share this post


Link to post
Share on other sites

Use a trailing grand summary part or a trailing sub-summary part - it depends on whether you want to print more than one invoice at a time.

See also:

http://fmforums.com/forum/showtopic.php?tid/188942/

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.