Shana Posted September 24, 2003 Posted September 24, 2003 I have a portal with several fields, let's just say there are 3 fields for example. When the cursor enters the third field, I need to call another script. I have one set up that works except for one problem. Assuming the three fields are labeld field1, field2, field3, and there is a global called field_name: Go to Field ["field1"] Loop Set Field ["field_name", "Status(CurrentFieldName)"] If ["field_name = "field3"] Perform Script [sub-scripts, "field3_script"] End If End Loop I placed the script on field1 so when the user clicks on it, the scfript begins to execute. However, without any pauses, the script freezes up entirely. I tried to add pauses except there is no way to determine how long the pauses should be for because some users will enter small ammounts of information very slowly while others may take a long time with vast ammounts since these field can and need to hold paragraphs of text. Is there anything I can do to make this script work effeciently? When I set the pause to a duration of 1 or 2 seconds the errors continually beep when it takes a long time. Thanks, Shana
Mike D. Posted September 24, 2003 Posted September 24, 2003 Shana, You might try inserting a Go To Field [] step after the Set Field step. Leaving the brackets empty forces FileMaker to save the record before continuing to the If statement. Just a shot in the dark, but it might solve your problem. HTH, Mike
Shana Posted September 24, 2003 Author Posted September 24, 2003 I tried that but it froze the file just as it does without pauses. Thanks though.
Mike D. Posted September 24, 2003 Posted September 24, 2003 Shana, Looking at your script again, you never give an exit criteria for the loop. You should add a step following after the Perform Script [sub-scripts, "field3_script"] step to exit the loop such as Exit Loop If [ ] Mike
Shana Posted September 24, 2003 Author Posted September 24, 2003 yes that was the problem...it works now!!! Thank you! (it's always the simplest answer)
Recommended Posts
This topic is 7734 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