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
benwrigleybenwrigley 

unlock an object after approval

Hi There,

 

I have an approval workflow on Opportunity that, on approval, sets a flag 'isApproved__c' to true and locks the Opportunity.

 

Is there a way in APEX I can unlock the object after this has happened? I want the user to have the chance to revise something that may have already been authorised and then force them through the approval process again.

 

Can anyone offer some advice?

 

TIA