Regular expression which doesnt allow special Characters

0
Do we have any regular expression to be used in microflow which doesn't allow special characters and throw validation
asked
3 answers
5

Hi Mohammed,

I usually check if my string only has characters which are valid. In this case you can use:

isMatch($String, '^[a-zA-Z0-9.]*$')

answered
1

regex: ^[\w\s-]+$

you can store this regex  in a string variable and perform isMatch function on the string. the above regex can be modified based to exclude the special characters 

 

answered
1

Hi Mohammed,

 

You can find more information about regular expressions on https://docs.mendix.com/refguide/regular-expressions.

The example that Sjoerd provides, is correct for only alphanumeric characters. 

You can test the regular expressions on https://regex101.com/

Hope that helps.

 

Cheers,

Jeffrey

answered