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.

new record in the remote db

Featured Replies

hi all,

i'm trying to set up a script that will create a new record in a data base that is related to the one that is performing the script and sets up the value of one of the fields of the newly created record to a randome number... the fields of the remote database are displayed in a portal in the database that will perform the script...

how do i do that????

thanks

Based on what you've said, one way to do what you want would be to:

Create a script in the related file with the steps:

Enter Browse Mode

New Record/Request

Set Field ["YourField", "Int(Random * NumericRange)"]

Toggle Window [Hide]


...and then call that as an external subscript from within your main file.

Depending on the set up of your relationship (ie whether 'Allow creation of related record' is enabled, you might alternatively consider setting the script in the main file to:

Go to Portal Row [Last]

Set Field ["RelatedFile::"YourField", "Int(Random * NumericRange)"]


from within the script in the main file

If you want your random number to be generated every time a new record is created - regardless of whether is is done with the script - you might prefer to place the formula which generates the random number in the Auto-enter by calculation options for the relevant field.

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.