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.

Conditional Field Entry - HELP!

Featured Replies

  • Newbies

How do I prevent entry into a field if another field already has data in it? I'd also like to display an alert that says "You cannot enter field X because this record is being used for data types described in field Y. Please create a new record."

Appreciate any help you can give!

JT

Hi JT and welcome to the forums!

If you don't want to be able to enter anything into field B if field A has something in it...

Go to define database, go to options for field B, go to the validation tab, choose validation by calculation, then just type IsEmpty(FieldA) //if field A is empty, the calculation will return 1 which means you can edit field B, if field A isn't empty, it will return 0 or nothing which means you can't modify field B.

Now the alert, hmmm, unfortuantly you can't use dynamic values like x and y but can enter some sort of other message in the display custom message if validation fails box:

"Cannot enter a value in Field B because this record is already being used for the purpose described in field A"

  • Author
  • Newbies

Thanks so much! I've been screwing with this for what seems an eternity!

Glad i could help :(

Actually... that validation message is kind of annyoing i've never really liked it.. another method would be writing the script below and then just attaching it to FieldB:

If[isEmpty(FieldA)]

Go To Field[FieldB]

Else

Show Custom Dialog["You cannot enter field X because this record is being used for data types described in field Y: " & FieldY & ". Please create a new record."]

End if

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.