web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

Ribbon Button Enable/Disable

(0) ShareShare
ReportReport
Posted on by

Hi Guys,


I need to enable and disable based on custom rule. I have used below code and called from enable  rule. This coding working, but show/hide instead of enable/disable. Please suggest any one.

 

code :

 

function customRule()

{

 var GetValue = Xrm.Page.getAttribute("new_custume").getValue();

 if (GetValue == 1) {

 return false;

   }

 else {

 return true;

    }

}

 

*This post is locked for comments

I have the same question (0)
  • Suggested answer
    Sayhaitokumar Profile Picture
    7,042 on at
  • Suggested answer
    Mahendar Pal Profile Picture
    45,095 on at
    RE: Ribbon Button Enable/Disable

    Hello Priya081990,

    Your code is working fine and this is by design, after CRM 2013, only enable ribbon  buttons are rendered by CRM UI, which means if your button is disabled it won't rendered in UI (so it's hidden).

    So when you will do enable/disable, it is actually show/hide now.

    Thanks

  • Community Member Profile Picture
    on at
    RE: Ribbon Button Enable/Disable

    HI,

    I need enable and disable.

    Regards

  • Community Member Profile Picture
    on at
    RE: Ribbon Button Enable/Disable

    Thanks for your reply .

    How can we achieve this ?

    Regards,

    kannan

  • Verified answer
    Mahendar Pal Profile Picture
    45,095 on at
    RE: Ribbon Button Enable/Disable

    You can't as this is by design, you need to educate your users about this new application change.

    Or alternative option is to develop buttons using html web resource in entity form and implement enable/disable behavior.

    Thanks

  • Suggested answer
    Jharana Baliyar Singh Profile Picture
    2,667 on at
    RE: Ribbon Button Enable/Disable

    Hi Priya,

    Try with this one :garethtuckercrm.com/.../dynamically-disable-ribbon-buttons-in-dynamics-crm

    Thanks,

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Abhilash Warrier – Community Spotlight

We are honored to recognize Abhilash Warrier as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

#1
HR-09070029-0 Profile Picture

HR-09070029-0 2

#2
ED-30091530-0 Profile Picture

ED-30091530-0 1

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans