+ Start a Discussion
si risi ri 

Need validation change

Requirement is to restrict certain users by entering or changing a lookup field value when a checkbox is enabled 
Here is my VR:
AND(Chexbox = true,OR(ISCHANGED (lookup), PRIORVALUE(lookup)= '' ),NOT( $Profile.Id = 'xyz') )
 But it failing to meet the requirement in some senarios.IS there any other way to write VR

Please try with below code in your validation rule. Replace the field names with your custom field API names. This rules prevent from users having profileid as in quotes, checkbox is true and if lookup field is being updated by them.
checkbox__c= true, 
ISCHANGED (Lookupfield__c)=TRUE , 
$Profile.Id = '00ef4000001ab2L' 

Note: Please use your API names of the fields in the rule or it doesn't work( API name for custom field will have __c in the end). 

Hope this helps!