Identify Special Characters in Text Feild


Is there any way to identify Special characters entered in the text field, and same thing i need to display the message saying “Special Characters are not Allowed”.


Since “special characters” means different things to different people and in different contexts, there’s no one answer. The simplest solution is to use a validation expression to identify acceptable characters. A regexp like this:

[a-zA-Z][a-zA-Z0-9 _]*

will allow only spaces and alphanumerics and underscores, but starting with a letter.

Edit: this is part of the FormattedTextField:

Welcome to the community!!

Here’s an example that may help you.

Thanks pturmel!

Thanks jlandwerlen!