Activity Forums Salesforce® Discussions Restricting characters and removing space at the end of a field?

  • Abhinav

    Member
    August 9, 2016 at 8:41 am

    Hi Tanu,

    You can use this formula example to validate against usage of those special characters and checking if there are spaces at the end.

    OR(
    CONTAINS( Text_Field__c , "'"),
    CONTAINS( Text_Field__c , '"'),
    CONTAINS( Text_Field__c , ","),
    CONTAINS( Text_Field__c , "*"),
    CONTAINS( Text_Field__c , "%"),
    CONTAINS( Text_Field__c , "@"),
    CONTAINS(RIGHT(Text_Field__c, 1), " ")
    )

    I hope this helps.

     

Log In to reply.

Popular Salesforce Blogs

Popular Salesforce Videos