function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Mac SwiftMac Swift 

Validation rule - To greyed out the opp stage

I have an opp stage which says "Sales order Approved" I want to make this opp stage greyed out for the sales rep and only update once the approval stage = "Approved". In order to restrict the users to select the opp stage "Sales order Approved" manually.

Please help me guys I want to do this through validation rule.
Best Answer chosen by Mac Swift
UC InnovationUC Innovation
Hi Mac,

Try this validation rule:
 
AND(
    opportunitystage = 'Sales order Approved',
    PRIORVALUE(opportunitystage) <> 'Approved',
    $Profile.Name = 'sales rep'
)
This won't grey out the option, but you will be unable to select 'Sales order Approved' unless the prior value was 'Approved'. It also makes sure this rule only applies to users with the profile of 'sales rep'. 

Hope this helps!

All Answers

UC InnovationUC Innovation
Hi Mac,

Try this validation rule:
 
AND(
    opportunitystage = 'Sales order Approved',
    PRIORVALUE(opportunitystage) <> 'Approved',
    $Profile.Name = 'sales rep'
)
This won't grey out the option, but you will be unable to select 'Sales order Approved' unless the prior value was 'Approved'. It also makes sure this rule only applies to users with the profile of 'sales rep'. 

Hope this helps!
This was selected as the best answer
Mac SwiftMac Swift
Thank you! Problem resolved!
UC InnovationUC Innovation
Please don't forget to choose the best answer to mark as solved! :)