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.

Validating Text in Global field

Featured Replies

To all,

I have a script that checks to make sure a 2 Letter abbreviation is entered into my Global field=Abbreviation.

I can check to make sure the field isn't empty but

Which function do I use to check it's not a number or the string contains a numerical value?

i. A2, 34, B8B, ABC9 etc

cheers in advance

Case(Position("0123456789",Left(Abbreviation,1),1,1),0,

Position("0123456789",Middle(Abbreviation,2,1),1,1),0,

Length(Abbreviation)>2,0,

1)

This will return 0 (logical false) for invalid values, and 1 (logical true) for a good value.

  • Author

Holy Cow!!, I wouldn't have thought of that, but it works a treat

Thanks Bob really appreciate the help smile.gif" border="0

  • 2 weeks later...

BTW, a tip about validating global fields: you don't necessarily need to use a script to perform the validation.

Try this: create a standard field of the type that the global field will eventually be (i.e., a number field if what you really want is a global number field). Set the validation for the field. Then change the field type from a normal field to a global field of the same type. The validation will stay with the field.

Chuck

BTW, a tip about validating global fields: you don't necessarily need to use a script to perform the validation.

Try this: create a standard field of the type that the global field will eventually be (i.e., a number field if what you really want is a global number field). Set the validation for the field. Then change the field type from a normal field to a global field of the same type. The validation will stay with the field.

Chuck

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.