Brian Dunning's FileMaker Custom Functions

GetSelectionƒ ( _fieldName ; _recordCount )

Akin to SelectionToArray in other programs, returns all values of a specified field from a given count of found records.

  Average rating: 4.3 (32 votes) Log in to vote

Michael Rhodes   Michael Rhodes
Allied Data Service
http://allieddataservice.com

Share on Facebook Share on Twitter

  Sample input:
GetSelectionƒ ( "id", get ( foundcount ) )
  Sample output:
"1¶2¶3¶4¶"

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

Recursive. Only use on fewer than 1,000 records.

Mimics list option in Summary field. Useful for older version of FileMaker.

 

Comments

Grubber   Grubber, UK
Apr 27, 2009
Thanks but doesn't seem to work?. Returns list of question marks?

Tried returning list to Global Var, Global Field and standard text field? WinXP/ FMA10.
 
Grubber   Grubber, UK
Apr 27, 2009
Opps, my mistake. Didn't spot it needs quotes around the field-name. Thanks. very useful.
 
Michael Rhodes   Michael Rhodes, Colorado Springs, USA
Mar 17, 2017
Fixed long-standing error with this function in that _recordCount needs to be converted to numeric value when comparing to FoundCount, lest ≤ be based on alphanumeric value.

The new'ish list option in Summary fields makes this function unnecessary.
 

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.