You need to sign in to do that
Don't have an account?

Hide standard 'Submit For Approval' button
Hi,
I have a custom button through which i am submitting a record for approval.
So i want to remove the standard 'Submit For Approval' and 'Recall Approval Request' button from the approval history related List.
I tried to create a Home Page Component to hide it, but it doesn't work.
Please let me know whether i am missing out something.
Below is my code:
<script>
$j = jQuery.noConflict();
$j("input[name='piSubmit']").hide();
</script>
Thanks.
I have a custom button through which i am submitting a record for approval.
So i want to remove the standard 'Submit For Approval' and 'Recall Approval Request' button from the approval history related List.
I tried to create a Home Page Component to hide it, but it doesn't work.
Please let me know whether i am missing out something.
Below is my code:
<script>
$j = jQuery.noConflict();
$j("input[name='piSubmit']").hide();
</script>
Thanks.
I can see this label in the home page and also the button is not hidden.
you can remove standard buttons from pagelayout through only. goto pagelayout edt-->select buttons--> remove
<script>
$j = jQuery.noConflict();
$j(document).ready(function(){
$j("input[name='piSubmit']").hide();
});
</script>
tvm Its Really works for me..
Thanks a lot for it..
Can you share me how did you implement it exactly?
Below is what I have tried unsuccessfully:
1. Create a new Visual Force page with apex script same as what tvm suggested.
2. Create a Home Page Component of above VF Page.
3. Add Component to the Home Page Layout (tried both Narrow and Wide sections there)
4. Navigated to the target custom object tab but still the Submit for Approval button is visible. Note that this is a standard button and not a custom button.
Thanks a lot in advance,
Hi,
I have the same problem of sindhu mani.
I have done everything as him and still have the button being displayed in the Approval History Related List.
tvm / Hd037 can you please explain how you have implemented this solution?
Thanks in advance.
I had to gone thru this before. what i finally did is develop a custom visualforce page and called related list in visualforce page wrapped with facet. It will hide the buttons and as you mentioned you are using custom button.. here is the code ..hope it will help. Only issue i had was i can't put that page in related list so i had to compromise to include the page in detail area.
Please vote if it helped you which give me encouragement to help others.
<apex:page standardController="Opportunity" extensions="Controller_Approval_History_Override">
<apex:messages />
<apex:relatedList list="ProcessSteps" title="Booking Guidelines Approval History" subject="{!Opportunity.id}" >
<apex:facet name="header">
<apex:form >
<div align="center">
<apex:commandButton id="submitBtn" value="Submit Booking Guidelines" action="{!submitApp}" rendered="{!isStatusNotPending}" />
<apex:commandButton id="recallBtn" value="Recall Approval Request" action="{!doRecall}" rendered="{!isStatusPending}" />
</div>
</apex:form>
</apex:facet>
</apex:relatedList>
</apex:page>