December 21, 200520 yr Do you have to put 'Allow User Abort [Off]' and 'Set Error Capture [On]' atop every script? I want these settings to be in effect throughout my app, with every script. I believe they are the system default settings. But after looking at various script examples and doing some tests myself, it seems you may have to keep reissuing them? Can anyone clarify? Thx.
December 21, 200520 yr Well you can make a subscript with a parameter that tells which of the 4 combinations you wish to use at this point in the main script, but the savings as such are pretty limited .... But more important is it that you as the developer not get yourself locked out of a never-ending loop - which I beleive is the reasoning behind not making it a default setting. We all seems to make mistakes here and there to some extend. --sd
December 22, 200520 yr I write every script with abort = off and capture = on, that way I know what the settings are at all times and I know the users cannot break the routines. To answer the question though, once the abort/capture settings are stated for a script, those setting remain in place for the duration of the script, and sub-scripts, unless they are changed mid-process (you may actually want to turn off capture occasionally - locked records etc.). Script defaults are capture = off, abort = on - that's if you don't set them explicitly.
December 24, 200520 yr Author OK. Even though they are the system defaults, I will make it a practice to put abort=off capture=on atop every script just to be sure. Thanks Søren and Mark.
December 27, 200520 yr A suggestion. I have a little script that gets executed at the beginning of (nearly) every script - user abort off hide status area (lock) [it also saves the layout number so I can return to it] While testing, I modify the sub-script to make life easy for myself and then fix it at the end to 'protect' users.
December 30, 200520 yr Author Very efficient -- a subscript called at the top of every script. Thanks for the tip, I'll have to use this.
Create an account or sign in to comment