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.

Child Creation w/out portals?

Featured Replies

Arrghhh -- I've spent the last half hour rooting around the forums in search of a thread I read last fall about various methods people use to create child records -- not by just typing into the last portal row (sloppy) or by scripting their way to a child layout (clunky) -- but by simply running a simple "Set Field" script that triggers record creation in the Child table via the realtionship (with record creation 'On').

I posted a question about this on a year-old thread, but not sure such things get seen by anyone:

http://fmforums.com/forum/showtopic.php?tid/193433/post/318322/fromactivity/myposts/#318322

Any help? I feel there something important here I'm not quite grasping, and I really need to!

Albert

See if these two methods can help you.

http://fmforums.com/forum/showtopic.php?tid/195614

IMHO, scripted creation is far from clunky (esp. since the introduction of script variables). I'd much rather have one more script than one more TO on the graph.

  • Author

I'm not averse to using a script, but I think I want to avoid scripts that do their job by going to a different layout, populating fields and then returning -- I have the impression there are techniques that get the job done more efficiently, and I am struggling with the tendency of FMP databases to suffer 'flashing' effects, which I fear might crop up with scripts that have to switch between layouts.

So, a simple script that hatches a child recrod by simply using a "Set Field" command would be very helpful!

--And thanks, John for the reference to the other thread -- will be exploring those demos.

Albert

Albert

I want to avoid scripts that do their job by going to a different layout, populating fields and then returning

Why? Layouts are gateways to tables - if you want to do something in a table, the most sensible way is to go and do it where it needs to be done. A simple Freeze Window should be enough to make the user completely unaware of what's happening "behind the scenes".

  • Author

Ok -- thanks for mentioning the freeze window step -- I had forgotten to use that.

Still, I'm going nuts here because I *know* there was a very lively thread in which a number of people weighed in on the merits of various child-creation techniques, but I just can't find it for the life of me . . . maybe I dreamed it up!

I'm still curious about these methods of creating child records without going to a layout, if nothign else to improve my understanding of how relationships work. I've been puzzling over the 'CreatorSansScript file John pointed to and just can't quite puzzle out how & *why* it works as it does. . .

Albert

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.