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.

When to Change Selected Layout during Scripting?

Featured Replies

If I want to create a new record during a script, I need to select the layout that is associated with that desired table.. (Freeze Window..  create new record .. in the background) ..

But if I just want to set fields in a particular table (set field Table::Field), If I do not change the layout, will those changes always be on the same / last record accessed on the non-visible table?

3 hours ago, Tony Diaz said:

But if I just want to set fields in a particular table (set field Table::Field), If I do not change the layout, will those changes always be on the same / last record accessed on the non-visible table?

No. The changes will be executed on the first related record (in the sort order of the relationship). This is assuming there is a relationship between the two tables - otherwise you will get an error.

In general, ANY reference to a field in a related table resolves to the first related record, unless you are in a portal. Or using it in an aggregate function.

 

Edited by comment

A method to create record in another table:

Create a Global Field in your table -

Create a relationship between main table and target child table from the global text field to the UID in the other table turn on create related records check box

UID_TEMP  ----- UID 

In your script you would set the UID_TEMP to Get(UUID) and then you can set any field you want in the other table with new data it will create a new record - just remember to also set the foreign key in that table with the primary key from the table you are on.

Once you are done setting fields you can remove the value in the UID_TEMP

 

Notes.fmp12

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.