You need to sign in to do that
Don't have an account?
WPCMS
Validation: Field can not contain spaces
I tried searching for this simple formula but could not find anything that would work for me.
We have an account code that needs to be manually entered by a user. The field is 12 characters long and should not have any spaces in it.
I tried
CONTAINS(Account_Code_c,"")
but it doesn't save on anything.
What other formula can I use?
Thanks in advance
My Regular Expressions are a little rusty and maybe someone can come up with a better way but you could use this:
NOT(REGEX(Account_Code_c, "([^\\s])+"))
All Answers
My Regular Expressions are a little rusty and maybe someone can come up with a better way but you could use this:
NOT(REGEX(Account_Code_c, "([^\\s])+"))
I tried
NOT REGEX( Account_Code__c ,"([^\\s})+")
and it said unclosed character class near index
so I tried
NOT REGEX( Account_Code__c ,"([^\\s})+")) (your suggestion)
and it says there are too many parentheses
Please copy, paste and edit to taste :)
NOT(REGEX(Subject, "([^\\s])+"))
The above works correctly. The formulas that you have posted do not include an opening parentheses after 'NOT'
It worked! Thank you.