pcourterelle Posted September 4, 2004 Posted September 4, 2004 hi...once in a whiloe when I'm testing script with a loop I'll goof and miss a step and create infinite loop, one that has no end. Is there a way to halt or exit the loop with keyboard commands? When this occurs I have to reboot the Mac to halt the loop. thanks in advance. pcourterelle
-Queue- Posted September 4, 2004 Posted September 4, 2004 If you don't have Allow User Abort turned off, then you should be able to hit Escape (Cmd-. I believe for Mac) Otherwise, try closing the file, either by clicking on the file's X or using the Mac equivalent of Ctrl-W (File -> Close). This will often work to close a looping file.
Fenton Posted September 4, 2004 Posted September 4, 2004 Another good idea, especially if you have a Loop within a Loop, is to put a button on the layout (temporarily) with the script step "Halt Script." That'll stop it. Of course, one always remembers to create the button WHILE FileMaker is stuck in the loop :-]
Fitch Posted September 5, 2004 Posted September 5, 2004 It's good practice to put something like this: Exit Loop If( Status (CurrentModifierKeys) = 1 and gDeveloperStatus = 1 ) ...inside all loops. That way you can always get out by holding the shift key. In this example, gDeveloperStatus is simply a global field that allows you to "turn off" the exit ability if you don't want your users to have it. So you can leave the Exit Loop in all your scripts, and turn them all off or on at once by just clicking the gDeveloperStatus checkbox (which is sitting on your hidden "Developer" layout, naturally -- another good practice).
pcourterelle Posted September 9, 2004 Author Posted September 9, 2004 Great ideas all...thanks phil courterelle calgary
Recommended Posts
This topic is 7383 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