You need to sign in to do that
Don't have an account?
Shekhar 13
Validation rule for Countries & Phone number code
Hello All,
I have a validation rule where there are 4 countries India, USA, UK & Australia and there phone number must start with +91 or +1 +44 or +61
Please advice .
I have a validation rule where there are 4 countries India, USA, UK & Australia and there phone number must start with +91 or +1 +44 or +61
Please advice .
Try Below Code Please Mark It As Best Answer If It Helps
Thank You!
You cannot take refrence from the below validation rule on contact.
Please follow the below validation rule in your required code
IF((MailingCountry='US' || MailingCountry='United States') && LEFT(Phone,2)<>'+1', True, IF(MailingCountry='India'&& LEFT(Phone,3)<>'+91', True, IF((MailingCountry='UK' || MailingCountry='United Kingdom') && LEFT(Phone,3)<>'+44', True,
IF((MailingCountry='AUS' || MailingCountry='AUSTRALIA') && LEFT(Phone,3)<>'+61', True, False))))
Please mark it as Best Answer if it helps you.
Thanks & Regards
Suraj Tripathi
>> https://developer.salesforce.com/forums/?id=9060G0000005d51QAA
The above link has an implementation that is similar to your use case and in it according to the mailing country code they are checking the country code in the phone field.
Let me know if it helps you and close your query by marking it as the best answer so that it can help others in the future.
Thanks.
try following validation rule.
above validation will be work when user select country and phone number should not be empty and phone number start with +.
I am sure above validation will help you. let me know if it helps you and marking it as best answer.
Thank you