AND(
NOT( OR($User.ProfileId="00e30000000geag",
$User.ProfileId="00e50000000vKto",
$User.ProfileId="00e50000000z2H8")
),
ISPICKVAL(PRIORVALUE( FAI_Status__c ),"DNS") ,
ISCHANGED( FAI_Status__c ),
OR(AND(
ISPICKVAL(priorvalue(Do_Not_Solicit_Reason__c), "Clearing"),
ISPICKVAL(priorvalue(Do_Not_Solicit_Reason__c), "Legal") )
)
)
the above validation rule is for users, outside of the profiles listed, that can make a change on a custom picklist field called "FAI Status" when the option is DNS. But those users cannot change the FAI Status from "DNS" when the Custom field called: DNS Reason has the following selections: "Clearing" or "Legal"
the rule is written for both fields DNS and DNS reason but how do i write the rule if the user only changes the DNS reason field from Clearing or Legal?
example:
the record has FAI Status = DNS and DNS reason = Clearing. user leaves FAI status at DNS but wants to change DNS reason to "non-clearing".
How do i write this rule?
Chad
$Profile.name = "Foo"
instead of$User.profileId = "someId"
- way more readable