klauern Posted June 28, 2004 Posted June 28, 2004 Hello all, I am implementing a button script that will show a set of records that match being marked as "Supervisor". I can get the script to work, however, when there are no records that are marked "Supervisor", a dialog pops up saying that No records match this request. This is all well and good, if you want to show that. However, I was wondering if there was something I could edit in my find script that would disable that dialog from displaying on the chance that there do exist zero records marked Supervisor?
-Queue- Posted June 28, 2004 Posted June 28, 2004 Set Error Capture [On] either at the beginning of your script or before performing the find.
QuinTech Posted June 28, 2004 Posted June 28, 2004 ... and immediately after the Perform Find step, add the steps: If ( Status ( CurrentFoundCount ) = 0 )
Oldfogey Posted June 29, 2004 Posted June 29, 2004 And don't forget to Set Error Capture [Off] after you've finished. Otherwise you'll lose every error.
QuinTech Posted June 29, 2004 Posted June 29, 2004 Paul, doesn't that reset at the end of every script?
-Queue- Posted June 29, 2004 Posted June 29, 2004 It's a developer preference whether you leave it on or not. I prefer to activate it at the start of a script and leave it on for the rest, unless trapping for an unknown error or performing a particularly sensitive export. Paul is advocating setting it off directly after a find has been performed and any errors trapped. But it depends what your script does afterward whether it has much effect. I prefer users never see one of FileMaker's error dialogs. God only knows what they would do with it to screw up a scripted process.
Oldfogey Posted July 3, 2004 Posted July 3, 2004 This is definitely a bottle of port and a warm fire discussion. Yes, I too hate the thought of users seeing one of FMP's sometimes weird error messages BUT I'd rather that than find out three weeks later that the data is totally screwed because a user didn't know something bad had happened.
Recommended Posts
This topic is 7710 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