Skip 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.

Dynamically setting a field's value

Featured Replies

  • Newbies

I'm trying to setup a utility script that I can use throughout my application to update a field based on a ScriptParameter.

In short, this is an example of what I want to do:

Toggle the value in the field Invoices::checkbox_value between 0 and 1.

When a button is clicked it triggers a script named "Utility|ToggleCB" and sends a scriptParameter value of "Invoices::checkbox_value" along with it. (Note: the script parameter is the actual NAME of the field, not the value)

The script then needs to determine the value of the field sent via the scriptparameter and act accordingly. My problem is getting that variable, or script parameter turned into the actual field value.

My bigger problem is multiple programming languages floating around in my head telling me a myraid of non-FM ways to do this.

Any help would be appreciated.

Well to get the fields value after passing its name as text via the scriptparameter, you can use either the Evaluate() or GetField() to get its value.

However, you can not directly assign values to a dynamic field name so it may not help you much anyway. It is a FM limitation that urkes many of us.

Take a look at this option though. It used to be on the FM forums home page but since been pushed off of it with other stuff.

Create an account or sign in to comment

Important Information

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

Account

Navigation

Search

Search

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.