I'm trying to use a regex in the Google Sheets data validation in order to ban the input of special characters, so basically my allowed set should be [a-zA-Z0-9,./()]
.
I'm using the custom formula input with the following =REGEXMATCH(TO_TEXT(range),"^[^a-zA-Z0-9,./()]")
but it now rejects everything including what is in my allowed set.
I've also tried the following variations and the results were the same as the above (everything is rejected):
=REGEXMATCH(TO_TEXT(range),"^[a-zA-Z0-9,./()]")
=REGEXMATCH(TO_TEXT(range),"[a-zA-Z0-9,./()]")
=REGEXMATCH(TO_TEXT(range),"[^a-zA-Z0-9,./()]")
=REGEXMATCH("[a-zA-Z0-9,./()]")
=REGEXMATCH("[^a-zA-Z0-9,./()]")
=REGEXMATCH("^[a-zA-Z0-9,./()]")
=REGEXMATCH("^[^a-zA-Z0-9,./()]")