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.

Suppress 'Quit' ?

Featured Replies

Hello all,

Is it not possible to suppress/disable the FileMaker Pro>Quit FileMaker Pro command in a particular layout? I'm developing a solution that has several modal/popup data entry layouts and it would be bad if the user quit FileMaker before the data entry was properly committed and certain housekeeping tasks could run. Do you suggest I install an OnLayoutExit trigger that could intervene (assuming it would execute before the app quits)? Thanks very much for your suggestions and/or workarounds.

  • 1 month later...

I'm working on a solution that needed to do something similar. I setup a script that would be performed on Closing. (Under File Options)


Show Custom Dialog ["Close Database";"Do you want to exit?"]

	  ## Choices are No;Yes

If [Get(LastMessageChoice)=1]

	 Halt Script

Else

	 Close File [Current File]

End If

Not sure if this is the "right" way to do it, but it works for me.

I was quite surprised to see that this actually works. I was thinking it had to be

Show Custom Dialog ["Close Database";"Do you want to exit?"]

## Choices are No;Yes

If [Get ( LastMessageChoice ) = 1]

Exit Script [Result: 0]

End If

Apparently Halt Script is the same as Exit Script with result 0. At least in this situation.

The biggest difference is that Halt Script terminates ALL running (or paused) scripts. Exit Script terminates only the script in which it appears.

I know that, but I was not aware that Halt Script also cancels the triggering event.

I know that, but I was not aware that Halt Script also cancels the triggering event.

I don't think it does. It sounds like that script was used in a Custom Menu to replace the File > Close option. That caused the command to be completely over-ridden by the script, unlike an OnLayoutExit script trigger.

I tested it out. The script as displayed above was set to run onFileClose. It functioned as described, no matter if I used Halt Script or Exit Script (result: 0). Mac OS Lion / FMA 11.0.4.

I setup a script that would be performed on Closing. (Under File Options)

silly me; I didn't read the post thoroughly. I assumed it was in the custom menu.

I also hadn't realized that the "run when closing" script responds to the script result; closing the file if the script result is empty or true. I don't think of this as a 'script trigger', considering it has existed in FileMaker for quite some. I think of a 'script trigger' as the the recent addition of layout and field level triggers (introduced in FM 10, I believe). Nonetheless, it is a script trigger.

Apparently Halt Script is the same as Exit Script with result 0. At least in this situation.

I wasn't aware of this either. I tested with a few other script triggers, and it works the same with them as well.

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.