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.

test for IsEmpty on multiple fields at portal row exit

Featured Replies

I have a portal in which all fields are required.

My script so far:

If [isEmpty (table::StaffID)]

Show Custom Dialog ["Validation Failure!! StaffID must have a value"]

Go to Field [table::StaffID]

Halt Script

End If

I have two problems to solve.

1) I want to invoke this script them someone tries to exit the portal row--all I can come up with is to apply a trigger to the last field, and have it implement on save or exit. What if the enduser skips the last field? (which they aren't suppose to do). Is there another way to do this.

2) There are a total of 4 fields in the portal and all four should be required. How do I modify the script to ensure that all four fields will require data?

1) You can use onObjectExit by right clicking the portal in Layout mode and selecting "Set Script Triggers" and that would trigger the script if the user tried to leave the portal or go to another row in the portal. Or you could set the trigger on each field exit (but then you'd have to have separate validation scripts for each field).

2) If you use onObjectExit for the portal, nest your validation script. ie:


If [isEmpty (table::StaffID)]

Show Custom Dialog ["Validation Failure!! StaffID must have a value"]

Go to Field [table::StaffID]

Halt Script

Else If [isEmpty (table::StaffFirstName)]

Show Custom Dialog ["Validation Failure!! StaffFirstName must have a value"]

Go to Field [table::StaffFirstName]

Halt Script

Else If [isEmpty (table::StaffLastName)]

Show Custom Dialog ["Validation Failure!! StaffLastName must have a value"]

Go to Field [table::StaffLastName]

Halt Script

Else If [isEmpty (table::StaffsWifesPhoneNumber)]

Show Custom Dialog ["Validation Failure!! StaffsWifesPhoneNumber must have a value"]

Go to Field [table::StaffsWifesPhoneNumber]

Halt Script

End If

  • Author

That works beautifully! Thank you so much for your quick and easy solution. I very much appreciate!!!

Create an account or sign in to comment

Important Information

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

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.