+ Start a Discussion

How to Disable a standard Button in salesforce ?

i want to disable a button based on a status. say quoting we have "email quote" button. this should be disabled till quote is in Approved status.please guide me on this ?

Any help would be greatly appriciated
Mudasir WaniMudasir Wani
Hello Aditya,

You cannot disable it using standard way.
You can remove the button from page layout 
Go to the object and found the page layout and remove that.

Previously we were using some java script in home page components but that is not an option to use now

Donot forget to select best answer to make our efforts visible in the developer forum.
Please mark this as solution by selecting it as best answer if this solves your problem, So that if anyone has this issue this post can help
In your apex page, you can have something like:
<apex:button action=??? renderd="{!status}">   this status is a variable in your apex class, can you can make it a boolean value, if it is true, enable, then false disable
You can do this :

Create two pagelayouts with the button enabled in one layout and disabled on other layout.And write a workflow rule which checks the status field value Based on the value write a field update to chance the recordtype id of required pagelayout.
Amit Chaudhary 8Amit Chaudhary 8
Hi Aditya,

Please check below link. This will resolve your issue:- 

Vetriselvan ManoharanVetriselvan Manoharan

Create a record type for status and display the page layout based on it.

Madhu D 24Madhu D 24

I have a query but i am unable to ask in question, so i am commenting here. If anyone knows kindly help me.

On Standard Object(account) i have a button Called SAD. The button is added over there by Visual force page.

Now my question is on Account page, for partcular field Picklist value (Eg.. Company type=''Z001') i want to disable the SAD button visibility to the all users.

Kindly help me guys.

Thanks in Advance.

Kind Regards
Madhu D