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.

ESC from Dropdown List (script trigger)

Featured Replies

A user is in a field which displays a dropdown list and hits the 'ESC' key, thereby selecting no item from the list. I'd like to trigger a script at this point, but it seems that simply closing the dropdown list by means of the ESC key, remaining within the same field, cdoesn't fall within the functionality of any of the script triggers. Is this correct? Is there a workaround?

 

Put in a different way, if a user hits the ESC key, opting not to select an item from the dropdown list, I want to close the popover which holds that field. Is this possible?

 

Thanks

Try attaching an OnObjectKeystroke script trigger to the field. Then have your script do the action if:

 Code ( Get(TriggerKeystroke) ) = 27

---

Sorry, that won't work in your situation. Apparently when a drop-down is activated, the ESC keystroke is interpreted as a keyboard shortcut to de-activate it and not passed further to the script triggering mechanism.

 

Edited by comment

  • Author

I had tried a trigger on the field, as well as one on the layout. I don’t seem to be able to trap for this. Tks. 

Maybe rethink the ux? Have them edit in a global in a popover with a save button? 

  • Author

I am using a global in a popover.

Do you have a save button in the popover? With that you can update the actual field. If they just dismiss popover, then the field is not edited. 

  • Author

There’s no save button. I use a script trigger to perform all required actions when a value is selected into the field. Should the user decide not to select an option from the drop down list, and instead hit the ESC key, I want the popover to close. I don’t see a way to accomplish this without the user having to hit the ESC key twice. 

I’m picturing something different. User clicks popover “edit” button next to noneditable field. Field value is set into global field using OnObjectEnter script trigger attached to popover. Global field has assigned value list. Popover save button sets global to actual field. Closing popover without clicking save does nothing.

  • Author

Thanks, but I do all possible to limit keystrokes. I don’t want to include a button. Someone selects an entry from the list, popover closes. 

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.