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.

Two fields, a portal, and a relationship

Featured Replies

Currently I have a portal based on data entered into a global field (let say gMake).

When clicking on a row of the portal, there is a script that populates other global fields, (gModel, gYear, gColor).

However, the specs for the interface has changed now, and now I have to have two fields but only one portal. In other words, Now I need gMake and gMake_Replace. When the user puts in Ford into gMake, then clicks on the appropriate portal record with button, it will populate gModel, gYear, & gColor. Then the user should click into field gMake_Replace. New values should come up in the same portal, and when the user clicks on the portal row, the fields gModel_replace, gYear_replace, gColor_replace should be populated.

Now, I wanted to try and do some kind of Get(ActiveFieldName) to execute what the last field was, either gMake or gMake_replace, when the user clicks on the portal row and executes the script, but once the portal is clicked, that function is no longer valid.

So I figured I need to match on some kind of third field (gLastfieldEntered) that holds the name of the last field that was entered.

It would be nice to execute a script once exiting a field to set this third field, but I didnt think it was possible to execute a script when a field is exited. Is there a plug-in of some sorts? I am not sure what I can do or the correct fields to use for this problem.

P.S. I dont think this was necessarily a portal question, so if I posted it eh wrong forum, then I apologize ahead of time.

  • Author

BUMP. Sorry.

Anybody have any ideas?

  • Author

Thanx Soren. I ended up finding the appropriate EventScript plugin and running a script to do it. Too bad I couldnt find it originally with the search that I ran. Maybe I just looked for the wrong keywords. I ended up finding out about it by just manually reading through past posts in the plugin section. That method works too. :-) Again thank you. I will look through the posted sample code in your post anyway out of curiousity.

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.