Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Specify field using script parameter?

Featured Replies

I have a script that can process one of five fields. What I want to do is use a parameter to specify which field needs to be processed by passing a 1 to 5 and then storing the parameter to a local variable.

Then I want to use the Replace Field Contents script step to replace the field specified to a 1 or 0.

For example, I have the following fields:

Field1

Field2

Field3

Field4

Field5

The field number variable is $FieldNumber.

It looks like I have to select the field that I want to change instead of using the following:

Evaluate( "Field" & $FieldNumber )

Is there a way around this without using the "Set Field" in a loop.

The target field for Replace Field Contents[] cannot be specified dynamically. Using Set Field [] in a loop will not change the basic situation - only Set Field by Name[] will accept a variable as the target field.

The simplest solution, IMHO, is to place five Replace Field Contents[] steps in a If/ElseIf/ElseIf… block.

Alternatively, you could use Go to Object[] or looped Go to Field[] to select the target field, then perform Replace Field Contents[] without specifying the target field. However, this requires all five fields to be on the layout.

Note also that having five "similar" fields is usually a sign of inadequate data structure.

Create an account or sign in to comment

Important Information

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

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.