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
Sachin Kumar 34Sachin Kumar 34 

Submit for Approval Button Need to Hide/De-active

I don't want to show the error message page/url when the record doesn't meet the criteria.

Approval Error URL Page

I want to Hide/de-activate the "Submit for Approval button", if record doesn't meet the criteria.
Best Answer chosen by Sachin Kumar 34
Amit Chaudhary 8Amit Chaudhary 8
Hi Sachin,

If you want to hide the button then you need to override the Detail page. You can try custom button
http://ofthecloud.blogspot.in/2013/09/custom-alert-message-on-salesforce.html

Please let us know if this button will help you

Thanks
Amit Chaudhary

All Answers

Amit Chaudhary 8Amit Chaudhary 8
Hi Sachin,

If you want to hide the button then you need to override the Detail page. You can try custom button
http://ofthecloud.blogspot.in/2013/09/custom-alert-message-on-salesforce.html

Please let us know if this button will help you

Thanks
Amit Chaudhary
This was selected as the best answer
Sachin Kumar 34Sachin Kumar 34
Hi Amit,

The code is working fine. but now i am unable to delete/remove the "Submit for approval" button from the Related list of Approval (Approval History).
I need to write the Jscript/Jquery for hiding the same or any other sol for this ?
Related_List_Button