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.

Why do I have to "Go to Next Field?"

Featured Replies

I hope my icon expresses frustration! I have a file with a bunch of self-relates. When you are in the current record, there is also a portal below which lists other records from the file that are related. If a row in the portal is clicked, then this should become the current record. I set it up by:

Set Field(gSelectedRecord,Portal Rlnship::Record ID)

Go to Related Record(Show,"Current Record")

where Current Record was defined as gSelectedRecord = Record ID.

When clicking the row, sometimes this would work and sometimes it wouldn't. After much troubleshooting, I realized that if I inserted Go to Next Field in between the two lines of code above, it always worked.

Does anyone know why this is necessary?!?!?!? I am stumped...doesn't seem right.

fyi...while troubleshooting, I separated the GTRR out into a button and on some records, the button would need to be clicked twice in order to work. WTF?

Set Field(gSelectedRecord,Portal Rlnship::Record ID)

Go to Related Record(Show,"Current Record")

where Current Record was defined as gSelectedRecord = Record ID.

It can get sometimes confusing when working with Portals in the same file. You must make sure what is the "source" file and the "target" file.

If your self relationship is set in the Main file (where the Portal is) as ??? Main:g_SelectedRecord::Selfrelation:Record_ID

Then, try to create a 2 lines simple script

Goto related record (selfrelation::Record_ID)

Goto Layout#

If what you are trying to do is "highlight" this row using the traditional calc c_Highlight = Case(g_selectedrecord = Record_ID, Container1, ""),

then you should have a script set as :

Goto related record (selfrelation::Record_ID)

Setfield (::g_selectedrecord,Record_ID)

One thing that you also need to keep in mind is the screen refresh. Filemaker (or any app) cannot always know when to refresh the screen, and this could be what is happening, you are going to the related record, but the screen is not refreshing. The Goto Next Field function causes a screen refresh.

Generally in self relationships where I am moving between records, I will include the Exit Record step, which also causes a screen refresh.

  • Author

Hey captkurt - you are right, I tried exit record in place of go to next field and that worked as well. Curiously, I had considered the refresh issue while troubleshooting and originally tried Refresh Window in place of Go to Next Field and that did not work. Anyway, it works now and for that I am thankful, just wish I understood a bit more about why.

Thanks!

Courtney

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.