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.

blur- and focus-type functionality?

Featured Replies

  • Newbies

Hi. Is there any way of getting onBlur and onFocus type functionality with FM objects in a layout? I want to run a script to check the contents of a text box field when it becomes deselected and then set the contents of another field accordingly. By the same token, can selecting a text box field trigger an event. thanks a lot....

Hi, hlc, and welcome to FM Forums! This is a, sort of, controversial function for FM. There are a few plugins available that allow you to trigger a script when the contents of a field are changed.

(Note that we're already off your question, as there is (AFAIK) no way to trigger a script from a field losing focus if its contents have NOT been changed. Anyways...)

So let's say you have this plugin and are aware that you need to change the contents of this field in order to trigger the script. And let's say the script you choose to run changes the contents of the field to "YOU ARE A WINNER!" Now, let's say that the user event that changes onFocus to False is a Go To Next Record command; FM detects that the field in record 1 has been changed, thus triggering the script, but by the time the script is triggered, you're on record 2 and have thus inserted the text from the script into the wrong record.

Long story short: It can be done, but it is fraught with peril. You have to have very good scripts to make it work.

If you can accept this, one of the plugins that will enable you to do this is ScriptIt from CNS Plug-Ins. There is another available, i think on the FM7 installation disc, in fact, but i can't remember its name.

HTH,

Jerry

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.