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.

Printing X number of labels, where X is calculated in a field

Featured Replies

  • Newbies

I need to print labels for items (products), and the number of labels (copies) for each product is calculated in a field of the database.

 

Each record calls for a number of items to be labeled with specific instructions for packing (date, location, etc.).

 

For example:

Record 1 calls for 3 items type no.1

Record 2 calls for 1 item type no.2

Record 3 calls for 7 items type no. 5, and so on...

 

I have duplicated the number of records in a separate database just for printing, but is so tedious (I have to process one record at a time) and is error sensitive.

 

The databases I work with, generally have between 200 and sometimes up to 2,000 records (or more) per database. And each one can generate from 200 to 5,000 labels (or more), that's why I'm looking for a more convenient solution.

 

Any ideas are really appreciated.

 

If I'm understanding you, you want to print multiple labels for each record in a found set, and that number will be different for each record. (Not sure if "item type" matters here or not.)

 

It might be useful to know how that  number is calculated. If it's based on a number of related records, you could just print from the related table.

 

Otherwise, I'd probably make use of a virtual table. You'd create a global text field (or $$variable), and a script that loops through your records, putting the ID of each record (or each item... depends on your data structure and what you need) into the global, multiple times based on the number of labels.

 

Your global field then drives a calculated field in a table that looks like:

 

GetValue( your Global ID List ; ID )

 

Search this forum for virtual list if you haven't heard of this technique.

  • Author
  • Newbies

Fitch,

 

Yes, I need to print multiple labels for each record.

 

The number is calculated in each record, based on the number of items needed determined by: multiplying the quantity by the number of sets to be used, and a unique identification number is assigned to the items in the record.

 

The item type can be used in multiple records in the same database, but the identification number is unique in each record.

 

I'll have a look at the virtual list you suggest.

 

Thanks!

Hi Luxpiro, welcome to FMForums!

 

I see Comment just posted a response and here is one also.  This file shows a method of achieving your result using summary ListOf and virtual list.  It is important that you use variables so that multiple Users could run it at same time.

 

 


Your LabelGenerator attachment isn't working, Michael.  Is this another one we have to tell ask Stephen to fix manually?

 

changed 'tell' to 'ask'

labels.fmp12.zip

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.