0

I am new to approval process. I am trying to validate two custom fields as not blank before the approval process has been submitted. I have done some r&d and found that is to set that restriction in place with the help of the Entry Criteria[1] in the Approval Process. The User would be taken to another page wherein the Error Message would be displayed saying that the Record didn't meet the Entry Criteria and failed to enter into the Approval Process.

But my doubt here is during setting up the approval for those two required field that I wants to check. Who will be the approver that I need to set up what will happen if the criteria meets ? If criteria meets i.e. user has populated both the fields how will other approval process will get trigger?

Can anyone please help me to set this approval process.

Thanks

  • why don't you just put entry criteria like those 2 fields not null – Ratan Paul Jun 25 '18 at 11:50
  • Actually I am having multiple approval process so you want me to put this criteria in each approval process that I have ? Please correct me if I am wrong – RAT__ Jun 25 '18 at 11:55
  • 1
    Yes Exactly just put the condition in all the approval process. – Ratan Paul Jun 25 '18 at 12:15
1

I am Jeff Du. We can't customize the displayed error message directly. We have to achieve it by coding.Now I can provide two solution for you.

Solution 1: Create a custom button with name "submit for approval",and execute javascript to validate the field value beforeto submit the approval approval process ;

Related resource:

https://developer.salesforce.com/forums/?id=906F0000000kF2JIAU

Solution 2: Create a custom button with name "submit for approval" , and redirect to a visualforce page to automatically submit the approval process and do the validation logic the in the related apex controller;

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.