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 field if other field(s) empty

Featured Replies

Hello. I have 4 number fields: N1, N2, N3 and N4. I would like to validate the fields this way:

N1 has to have a value (I was thinking checking Not Empty here?)

N2 cannot be entered if N1 is empty

N3 cannot be entered if N1 and N2 are empty

N4 cannot be entered if N1, N2 and N3 are empty

I was playing with validating by calculation but was not able to make it work.

Thanks in advance for help.

FileMaker Version: 6

Platform: Windows 2000

I played around with this. You need a validation by calc for each field to look at its previous field only. N4, for example, should have a validation by calc of:

If(IsEmpty(N3), 0, 1)

This will allow entry only if N3 is not empty. It assumes (by the other validations) that you can't get to N3 without N1 and N2 being filled. In my test, I checked the "Strict" box (so users can't override validation) and the "show custom message," where I typed the message "N1, N2 or N3 is empty. You cannot use this field yet."

Do the same for all three (N2, N3, N4), as:

N2 = If(IsEmpty(N1), 0, 1)

N3 = If(IsEmpty(N2), 0, 1)

N4 = If(IsEmpty(N3), 0, 1)

N1 is a special case. I tried simply checking the "Not Empty" box on validation, checking "Strict" and using the custom message "This field must contain data."

I've attached a small test file. See if this works for you.

Steve Brown

  • Author

Steve, works perfectly. The way I need. Thank you very much.

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.