0

I have a picklist field with values Plan A, Plan B and Plan C. I need to display picklist values in such a way that if another Custom lookup Field's value (say Book__c) includes the keyword 'History', only Plan B and Plan C values display and if Book__c includes the keyword 'Literature' all 3 picklist values display. How to achieve the same. I suppose validation rule is the solution, but could you please help me with the formula.

  • you need this while record insert or update and error must be on the page layout, right ? – Nihar Aug 3 '17 at 7:53
  • Yes, actually the picklist value should be updated on detail page. – Salesforce Learner Aug 3 '17 at 8:33
0

Display picklist value as per the lookup field is not so possible by the validation rule but if you need to restrict the picklist value then yes you can do by the following piece of code,

If another Custom lookup Field's value (say Book__c) includes the keyword 'History', only Plan B and Plan C values display

You can set your validation rule something like this :

AND(Book__c = 'History' , ISPICKVAL( Picklist_Field__c , 'Plan A'))

Hope it helps you out !!

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.