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.

Using GetAsNumber("") as a boolean value for false

Featured Replies

I am migrating a database written in FMP v3 that I did not write to FMP v7. I have found that the author uses tests like:

If ( <condition> ; 1 ; GetAsNumber("") )

...in number fields that act like boolean flags. Does anyone have any idea why he would use GetAsNumber("") to mean false instead of the number zero? I'm not even clear on what GetAsNumber("") returns-- I think it sets the field to empty/no value.

Thanks for your input.

The developer may have wanted to use Count( ) on the field, or some other function where 0 would interfere with the result. TextToNum( ) or GetAsNumber( ) is often used when converting text values. It never seems to be necessary when setting null though, whereas TextToDate("") is vital unless you want a question mark in a date field.

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.