ZapValues ( ListA ; ListB )
Removes the items in ListB from ListA.
Average rating: 4.3 (48 votes) Log in to vote
Function definition: (Copy & paste into FileMaker's Edit Custom Function window)
The ZapValues function removes from ListA any values which are found in ListB, where ListA and ListB are carriage-return separated text lists.
This provides the logical inverse of FileMaker 7's built-in FilterValues( ) function.
Mark de Haas Meijer, Almere
Apr 6, 2010
|Cool function. Thanks!|
Jun 15, 2010
Very useful !
I've tried to make it, without success.
Thanks a lot :)
Justin Pakes, Virginia, USA
Jul 17, 2012
Thank you! I have tried 4 of these functions here to date, and this is the only one that handled properly when value being removed was at start of list twice.
ZapValues ( "a¶a¶b¶c¶a" ; "a" ) does return "b¶c"
Jon Klassen, Alberta, Canada
Aug 12, 2014
Here is the function without a Return at the end, The function name has been changed to 'RemoveVales';
IsEmpty ( ListA ); Let( $repRemoveValues = ""; "");
value = LeftValues(ListA; IsEmpty(FilterValues(LeftValues(ListA; 1); ListB)));
value_trim= Substitute(value;¶; "");
$repRemoveValues = If( not IsEmpty(value); $repRemoveValues + 1; $repRemoveValues);
cr = If($repRemoveValues > 1 and not IsEmpty(value_trim); ¶; "")];
RemoveValues(RightValues(ListA; ValueCount(ListA) - 1); ListB)
Jan 17, 2019
|Wow - this is so helpful! Thank you.|
Note: these functions are not guaranteed or supported by BrianDunning.com. Please contact the individual developer with any questions or problems.