Brian Dunning's FileMaker Custom Functions

VariablesFromObjects ( )

passes the content of all named objects on the layout to named variables

  Average rating: 4.4 (27 votes) Log in to vote

Fabrice Nordmann   Fabrice Nordmann
1-more-thing
https://www.1-more-thing.com

Share on Facebook Share on Twitter

  Sample input:
the layout contains :
field "A", named "field_A" that contains "1",
WebViewer named "wv_B" that contains "2",
text label named "lbl_C" that contains "3"
  Sample output:
$$field_A will contain "1"
$$wv_B will contain "2"
$$lbl_C will contain "3"

  Function definition: (Copy & paste into FileMaker's Edit Custom Function window)

Load dynamically named global variables with the content of the named objects of the layout.

UPDATE : I would now recommend the use of CustomList, by Agnès Barouh : http://www.briandunning.com/cf/747
Calculation would be :
CustomList ( 1 ; ValueCount ( LayoutObjectNames ( Get ( FileName ) ; Get ( LayoutName ))) ; "let ([ $o = getvalue ( LayoutObjectNames ( get ( fileName ) ; get ( layoutName )) ; [n] ) ; $c = getLayoutObjectAttribute ( $o ; \"content\" ) ]; VariablesLog ( $o ; $c ))")

 

Comments

Log in to post comments.

 

Note: these functions are not guaranteed or supported by BrianDunning.com. Please contact the individual developer with any questions or problems.

Under construction. Email me your wish list for improvements.