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

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

Recommended Posts

Posted

How can I set a global value rather a repetition number in a Set Field script?

For example:

Set Field["File2::Field1"-global value,"expression"] (this syntax is not valid)

rather

Set Field["File2::Field1"-3,"expression"]

Posted

Although there are valid reasons for using repeating fields, they are generally only within developer fields, such as global container fields to control interface elements.

Having said that, there's no direct way to set a particular variable repetition. This can, however, be done with a script.

Place the repeating field on a new layout by itself. Make sure that the repetitions for the field are visible on the layout.

Next, create a global number field called gCounter. Use this script to fill in the repetition specified in a global field called gRepFill with a value in the field RepetitionFill.

Set Field [ gCounter, 1 ]

Go to Layout [ RepeatingField ]

Loop

Posted

Go to Next Field will take the cursor to the next field that would be entered by hitting the tab key. If the next field to be entered is the next repetition, then it will take the cursor to that.

Quoting from the online help:

Moves to the next field of the current layout. If no field is selected when this script step is performed, it moves to the first field of the current layout. FileMaker Pro uses the tab order to determine the next field on a layout.

Chuck

This topic is 7918 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.