Topics   All   Mac OS X (Only)   Windows (Only)   Linux (Only, Not)   iOS (Only, Not)  
Components   Crossplatform Mac & Win   Server (Not)   Client   Old   Guides   Examples
New in version: 6.3   6.4   6.5   7.0   7.1   7.2   7.3   7.4   7.5   7.6    Statistic  

QuickList.MatchesPrefix

Finds list entries which have a given prefix text.

Component Version macOS Windows Server FileMaker Cloud FileMaker iOS SDK
List 5.4 Yes Yes Yes Yes Yes

MBS( "QuickList.MatchesPrefix"; ListRef; Text { ; Flags } )

Parameters

Parameter Description Example value
ListRef The reference to the list returned from QuickList.New function. $List
Text The text to find. "Hello"
Flags Optional
Pass 1 to return result as new QuickList. This new list must be freed later using QuickList.Free function. Pass 0 (Default) to modify the list in the List1 parameter.
Add 2 to split. This is only useful with first option together (so pass 3 for both). Matching entries will be in new list and non matching entries will stay in old list.
Add 4 to reverse operation (NOT).
0

Result

Returns OK, list or error.

Description

Finds list entries which have a given prefix text.
Comparison is case insensitive.

Examples

Finds list entries with same prefixes:

Set Variable [$list; Value:MBS( "QuickList.New"; "Hello¶World¶auto" )]
Set Variable [$matchesList; Value:MBS( "QuickList.MatchesPrefix"; $list; "w"; 0)]
Set Variable [$text; Value:MBS( "QuickList.GetList"; $list)]
Set Variable [$r; Value:MBS( "QuickList.Free"; $list )]
Show Custom Dialog ["result"; $text]

Find entries not matching in prefix:

Set Variable [$list; Value:MBS( "QuickList.New"; "Hello¶World¶auto" )]
Set Variable [$matchesList; Value:MBS( "QuickList.MatchesPrefix"; $list; "w"; 4)]
Set Variable [$text; Value:MBS( "QuickList.GetList"; $list)]
Set Variable [$r; Value:MBS( "QuickList.Free"; $list )]
Show Custom Dialog ["Result"; $text]

See also


QuickList.MatchesPostfix   -   QuickList.MatchesSubString

Feedback: Report problem or ask question.




Links
MBS Xojo Plugins