Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

This topic is 7231 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

The script Opens a file. If the user hits the Cancel button during the log-in, the script will never open that file again until the database file containing the script is closed and reopened. The FileMaker application does not have to be restarted.

I have tried Get(Last Error). It returns the error, but does not "reset" whatever is going on.

Any suggestions?

Lynn

Posted

If you have Allow User Abort [Off] before the call to open the external file, a user should not be able to click any Cancel button, because only Continue would exist. If you Hide and Lock the status area, neither button will be accessible, by the way.

Posted

"the script will never open that file again until the database file containing the script is closed and reopened"

You should only have to perform the script again, not have to close the file. If the script is run when the file opens and there is no other way for the user to perform the script, then it's an interface/design issue.

Maybe if the user cancels the script change to a layout with a big button on it "Try Again" that performs the open script.

Posted

Maybe I was not clear in my original post.

The script runs when the file (file A) opens.

Set Error Capture [On]

Open File ["Vendor File"]

If [Get ( LastError ) <> 0]

{corrective Action goes here}

When the Open file step executes, the user is asked for Account and Password for the Vendor File.

If the user hits Cancel in the log-in dialog (NOT the Cancel Script button), Get ( LastError) returns 1.

Re-running the script does not open the Vendor File or give a log-in dialog. I have to close file A (containing the script) and reopen it before the script will attempt to re-open the Vendor File.

Posted

Hmmm... FMP 7.... it may well be another "difference" between FMP 7 and FMP 6. Or a bug.

  • 9 months later...

This topic is 7231 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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.