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
mukesh guptamukesh gupta 

Related List Button hide and show

Hi Expert,

On the oppertunity page i want to hide a related list button if oppertunity stage changed.

User-added image
Deepak Maheshwari 7Deepak Maheshwari 7

Hi Mukesh,


Through standard functionality, we cannot hide or show the related list button on stage change.
If the button is custom then we can add javascript in that to show an error message if anyone clicks on button.

Hi Mukesh,

There is workaround for this. For that you have create 2 record type with 2 diffrent Page layout (One with related list  with button and another without button). Make the the 1st record typed default record type and on stage change change the record type.

Let me know if its work for you

Mukesh, Record Types would be the solution to this and with two different page layouts as well. You can have a workflow which will change the record type and then record will be assigned new page and button will be hidden