I would like to have a regular expression that checks if the string contains Alphanumerics, Hyphen and Underscore. There should not be any spaces or other special characters other these three. My string will be under either of these 2 patterns.
I have already tried this expression. But it didnt workout. [[a-zA-Z0-9_-]*]