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
Lauren BeHage 6Lauren BeHage 6 

Customize How Records Get Approved with Approvals - If approved, set the Type field to 'Customer' and unlock the record.

Hello -

I have the field update set to update the Type to Customer, if the process is approved. However, I'm getting the following error. I believe I'm getting this incorrectly.. please advise..  "The process did not set the correct Type value when approval outcome is Approved"
NRD 4 UNRD 4 U
Hi Lauren,

Not sure when are you getting this error whther you are trying to approve and update through apex code. Can you please elaborate what process is here, is it an object and where is Type, is it in account?
If you want to achieve this for a single object then its very easy through approval process to update a certian field on approval by adding a field update.

Thanks!
Lauren BeHage 6Lauren BeHage 6
Thank you! i'm working on this trailhead.. when I believe it's checking the challenge in order of the bullet points and failing at the second to last.. failing because my Type field value upon approval isn't matching the expected value. I've had two peers review my work and they can't make sense of it.  https://trailhead.salesforce.com/business_process_automation/approvals   hopefully you can see the details in the picture below. we're thinking it may be a glitch in the trailhead? 

error message on trailoverall approval processfield update which i think is erroring out
NRD 4 UNRD 4 U
Hi,

Please add the field update as final approval action. I think in approval process-> final approval action you have not added any action. Might be because of that you are gitting the error. If you still face any issue, please give me your developer account credentials, I'll check the same.

Thanks!
NRD
Lauren BeHage 6Lauren BeHage 6
Thanks for your help.. i figured it out.. thank you!