You need to sign in to do that
Don't have an account?

Make a field requirement dependent on a picklist value
I have a new field I created called Client lead Source. I would like to name that field required based on 2 other picklist fields called "Primary Lead Source" and "Secondary Lead Source". Once the picklist value for both is equal to "Client", this new field would be required. I am not exactly sure how to accomplish this.
1) Make a page that behaves such that when the record updates the FieldSet attributes of the custom field will be changed to required. See docs :
https://www.salesforce.com/us/developer/docs/apexcode/Content/apex_methods_system_fieldsets_describe.htm
2) When the trigger executes ensure that the picklist values of the fields Primary Lead Source and Secondary Lead Source are checked.
example:
Cyrus Talladen
CRM Engineer
www.levementum.com
Cyrus T
www.levementum.com
not(
and(
ispickval(Primary_Lead_Source__c, "Client"),
ispickval(Secondary_Lead_Source__c,"New Business"),
isblank(text(Client_Lead_Source__c))
))
not(
and(
ispickval(Lead_Sources__c, "Client"),
ispickval(Secondary_Lead_Source__c,"Client"),
isblank(text(Client_Lead_Source__c))
))
And then I get this error since Client Lead Source is a text area:
Error: Incorrect parameter type for function 'text()'. Expected Number, Date, DateTime, Picklist, received Text