Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Purposely causing extra portal rows to appear

Featured Replies

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

  • Author

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?

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

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

  • Author

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.

  • Author

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

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.

  • Author

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.

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/

  • Author

Everything is working great now. Thank you both for all the help!

Create an account or sign in to comment

Important Information

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

Account

Navigation

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.