PKF Posted December 12, 2014 Posted December 12, 2014 If a user indicates he/she wishes to exit the database, this script progresses appropriately to the 'Exit Application' step, but then loops back to the custom dialog a 2nd time! On the second pass through the script, the database closes. Any idea how this could happen and how to avoid users having to respond twice about exiting a database? I'm stumped. The same looping occurs if using the 'Close Window' or 'Close File' steps.
Wim Decorte Posted December 12, 2014 Posted December 12, 2014 Do you have any OnClose events that you attached scripts to?
PKF Posted December 12, 2014 Author Posted December 12, 2014 Any help for this poor misguided would-be database designer would be appreciated. If a user indicates he/she wishes to exit the database, this script progresses appropriately to the 'Exit Application' step, but then loops back to the custom dialog a 2nd time! On the second pass through the script, the database closes. Any idea how this could happen and how to avoid users having to respond twice about exiting a database? I'm stumped. The same looping occurs if using the 'Close Window' or 'Close File' steps. Here's the actual script: # Script exits database Show Custom Dialog ["Exit Database"; "Do you wish to exit database?"] Set Variable [$UserInput; Value: Get(LastMessageChoice)] If ($UserInput = 1) Exit Application // Close Window [Current Window] // Close File [Current File] End If Exist Script
Jim Gill Posted December 12, 2014 Posted December 12, 2014 Not sure about your "Loop"  since your script does not contain one.  Also be sure you don not have a script trigger assigned to your button which could cause a perceived loop. Also remember the buttons assignments  1,2,3  are opposite to the displayed buttons for the user.  See attached.  Hope this helps or leads you down the correct path.Â
comment Posted December 12, 2014 Posted December 12, 2014 This is a duplicate of: http://fmforums.com/forum/topic/94446-exit-script-loops-inappropriately/ Please post your issue only once.
Lee Smith Posted December 12, 2014 Posted December 12, 2014 I merged your two topics into this one. Please do not multiple post your questions. There are lots of reasons if you want to know what some of whom are Private Message me
Recommended Posts
This topic is 3633 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now