0

On opportunity object I have a picklist with values: 'Y' and 'X'. When opportunity has 'X' value user should be able to click button if has 'Y' when user click the button then should receive a information that value 'X' is needed to proceed.

Only value 'X' should allow click the button.

Does anybody know how in Salesforce achieve this ?

0

You can create Javascript button.

Below is the code snippet you can use in js button. I have considered account object as an example.

{!REQUIRESCRIPT('/soap/ajax/26.0/connection.js')} 
var accReq = "{!Account.Field__c}";
if(accReq != 'X') {
  alert('Only value X should allow click the button');
}
| 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.