Text Match Bug?

Found some weirdness with the Match Text component in Grasshopper.

Can someone explain why in this instance it is not just matching the character, but also “*” and “?”.

text match bug.gh (12.7 KB)

ps: what i am trying to do is get the index of each character in the input word from the list of characters.

Info from the posts linked below:

Patterns use the VB Like operator which supports:

? (any single character)
* (any number of characters)
# (any single digit)

Text filter - Grasshopper (grasshopper3d.com)

If you set C to False then the casing of text is ignored. “B” is the same as “b”.

[help] About “Match Text” component – Grasshopper (grasshopper3d.com)

1 Like

You could use the unicode values of the characters instead, but you would have to edit your Character list on the left side.

1 Like

Since the mentioned characters are wildcard characters the easiest way is to ensure they are escaped. Note the backward slashes here:


Oh, of course, that makes sense. Good to know you can escape them though!