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.

Global Field Not Setting

Featured Replies

I have a situation that I can't seem to solve. Here is the setup:

Task: Create a new record and insert the ID of the record that the script was triggered from.

Script steps:

Set Field [GlobalTemp::gTempNum; Get(RecordID)]

Go to Layout ["Action Items" (Action Items)]

New Record/Request

Set Field [Action Items::AI_id; GlobalTemp::gTempNum]

Commit Records/Requests [No dialog]

Go to Field [Action Items::XI_item]

Unfortunately, the field AI_id never gets set and the global field gTempNum does not contain the record ID of the record that triggered the script. I did make sure that the table GlobalTemp has at least one record (the only field is the global field).

Does anyone have any ideas what I am doing wrong here?

Thanks in advance!

Ken

I would first start at making sure that the global field is indeed global. Many times people will name their field as a global but then forget to check the global storage checkbox.

Is the Get(RecordID) information what you really want to get ?

This is a number internally generated by FileMaker, not a serial number you would have created to identify a record...

But if it is what you want I've just tried again (FM8.5), it works fine. It could be that your field GlobalTemp::gTempNum in not set as a global...

Can't help you more.

--EDIT--

sorry, dobble post with John...

--EDIT--

Edited by Guest

  • Author

Thanks for the comments. The field is indeed a global. I did notice that I didn't have any actual records in that table though, so I created a single record, but that didn't seem to make a difference.

You are correct though that Get( RecordID ) is not what I really wanted. I was trying that as part of troubleshooting because it was not working when I tried to assign my primary key. I finally got it to work with my primary key (I think I had accidentally assigned the wrong field before).

I still have no idea why I couldn't assign the recordID though. Strange...

Anyhow, problem solved and on to better things. Thanks again for the help.

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.