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.

Sub for value List in Scripted validation

Featured Replies

In a very complex Invoice validation situation, I need to avoid all field-level validation. Therefore, I am collecting and validating all the data by script. One of many validation parameters is:

The part number entered in the temporary gPart# field must be a number contained in a field in the Parts database.

In field-level validation this would be easy. But in a script, how can I say something like:

If(Part# is not a member of Parts::Part#),

ShowMessage [This is not a valid number]

End If

I can't find anything in the manual that I could do, short of scripting a full-on Find request and error message collection.

If you are collecting data into global fields and validating those prior to writing the data to a record, I assume that you are doing so on the request of a user to add an item to the invoice? If so do not let the user proceede until ALL validation errors are cleared up.

As soon as you find an error, simply alert the user and return them to the editing screen so that they can correct the error.

  • Author

Yes, this is the case. I have the user fill out all the temp fields, then hit an "add" button which triggers the validation script. For the part number field, I want that script to validate part numbers by scanning the parts inventory database and triggering an error message if not found. What is the best way to do this?

Setup a relationship ValidPart = gPartNumber::PartNumber. Then a simple calc to validate IsValid ( ValidPart::PartNumber ) and you are done.

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.