Skip 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.

Print Script-Using current record

Featured Replies

Hello All! I am working a db application that tracks conduct/discipline for a school principal. I need to set up a script to print a certain layout dependent upon a text value in a particular field. For example:In the current record IF the Field Punishment_ID = "001" then go to layout "ISR Letter" and print 3 copies using the current record IF the Field Punishment_ID = "003" then goto layout "Suspension Letter" and print 3 copies using the current record...I am new to this so I am not sure what the procedure to do this would be. Thanks

[ November 14, 2001: Message edited by: Matt Johnson ]

In the script, use:

If[status(CurrentFieldName)...]

No that won't work. We aren't interested in the field name.

If [ Field Punishment_ID = "001" ]

Go to layout [ "ISR Letter" ]

Print []

Else

If [ Field Punishment_ID = "003" ]

Go to layout ["Suspension Letter" ]

Print []

End If

End If

Note that the function to "print 3 pages" is best done by the user when the print dialog box appears, rather than issuing the Print [] step three times.

Note also that if the Field Punishment_ID is neither 001 nor 003 then the script as written above won't print anything, but this is the logic you have described in your post.

  • Author

Thanks Guys. I worked it out but did it a little different. The main problem I had was that "001" was not the true value, but "1" was really the value. After I got rid of the zeros it worked. Now I will have to make another post because I need to do some reports which probably entail some calculations...I getting better at all of this!

Just off the top of my head:

You can have the script go to the appropriate layer automagically by using Go to Layout (by # from a field), and specify Punishment_ID as the layout # to go to. Or, at least, a calc field based on Punishment_ID.

e.g. If Punishment is Suspension, Punishment_ID=3, Go to Layout 3, which would be Suspension Letter.

Hope this makes sense.

Create an account or sign in to comment

Important Information

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

Account

Navigation

Search

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.