I want to hide some optionset
values from Disqualify
button; actually these are statusreason
of disqualify state
.
I can do this with any field
on the form with simple JS
.
But for a button in ribbon( like Disqualify Button ), I do now know how to do this.
I googled, but did not found any similar issue.
issue is this :
I have some option set values in disqualify button of lead(which are statusreason
of disqualify state
) that are not necessary any more.
I can not delete them, because my history and report will destroy.
So I need to hide them, But the disqualify button is in ribbon and I do not know how to access that.
Note that I am aware how to work with ribbon workbench; if it is necessary to work with.

- 179
- 1
- 2
- 11
1 Answers
I followd this thread and find a way.
@Andrew Butenko answer's solves the problem.
In his youtube video, he shows how to do this.
According to the video, in the first function he writes; he uses xml
to populate the flayout
. But you can do this via ribbonworkbench
visual tools and add your buttons to flayout
menu section. there is no need to write the first function.
But to do this you must set your command to each button you add.
Also somebody replied my question in this thread in the microsoft community; But I did not try that. The solution is similar to what I said.
But actually I changed my way.
I write a WorkFlow
that in it's condition I check the satusreason
and It's trigger is on statusreason
.
When the record goes to that special statusreason
, I stop the workflow with status of canceled with a message that : This status is not valid anymore.

- 179
- 1
- 2
- 11