When a geological rift forms, scientists see discovery and possibility. What will you discover?

Insert Merge Variables

I came across this post on the FileMaker forum, and thought it was a good idea to share. Simple, effective.

[ Tip ] Insert Merge Variable
03-25-2010 01:06 PM by mr_vodka

Just thought I would share this with others; especially those that have not played with merge variables yet ( dunno if it has been shared on other sites yet ).

With the implementation of layout level variables, they can be used as layout level calculations.

To address the refreshing of the data one could use an OnRecordLoad and call a script to refresh the data using Refresh Window [].

However, this looks horrible with the flash particularly on Windows. A better way would just use a Freeze Window.

To refresh the layout merge variable values just call a script with a single Freeze Window step. Allow the setting of the variable to be set as a Script Parameter. Then you can reuse that generic script everywhere.

For example let’s say that you wanted to update the record number of found count display

Well you can use OnRecordLoad, with a script parameter of:

Let( $$fndknt = Get ( RecordNumber ) & ” of ” & Get ( FoundCount ); “”)

Call the generic script which only has the Freeze Window step in it.

On your layout, you should have the inserted Merge Variable $$fndknt on it. No more having to create a supplemental calc or use web viewer.


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s