locked
Change Mscrm Button Label Text Dynamically RRS feed

  • Question

  • HI ,

    I have an Requirement, need to change the Button Label text dynamically. 

    Can you suggest me how to achieve this. 

    plz provide some sample code / Reference. 

    Thanks In Advance. 

    Friday, June 26, 2015 1:25 PM

All replies

  • which label you want to change? post a screenshot

    My blog: www.crmanswers.net - CRM Theme Generator

    Friday, June 26, 2015 1:44 PM
  • Hi Guido ,

    We are Having  Few CRM Button . 

    we need to Dynamically change the text of the Button label. can you Guide how to achieve.

    Plz provide some sample code or reference link .

    Attached Screens Short For reference.

    • We need to Modify the Button label text dynamically . 

     

    • Edited by kMAT1 Monday, June 29, 2015 8:20 PM Wrong Comments
    Monday, June 29, 2015 2:49 PM
  • I don't think there's a supported way to change the button text. An alternative approach might be to create several buttons with different buttons, and use display rules to show the button with the appropriate text

    Microsoft CRM MVP - http://mscrmuk.blogspot.com/ http://www.excitation.co.uk

    Monday, June 29, 2015 8:43 PM
    Moderator
  •   HI DavidJennaway

    Thanks for the reply. Currently we are proceeding on the approach as you have mentioned. 

    Yes, that is Un supported Customization. Can we update using Js on load event ? . Using DOM manipulation. ? 



    Monday, June 29, 2015 9:51 PM
  • Any Update ??

    Tuesday, June 30, 2015 5:10 PM
  • Can Any body Suggest me on this how to proceed further ??? 

    • Edited by kMAT1 Tuesday, June 30, 2015 10:21 PM
    Tuesday, June 30, 2015 10:20 PM
  • Use a Ribbon button editor [https://ribbonworkbench.uservoice.com/knowledgebase/articles/71374-1-getting-started-with-the-ribbon-workbench] and remove the existing button. Create two new buttons with with different labels and set the enable function to custom javascript to hide one and show the other.

    Of course the challenge with this is that if your requirements are truly N options for the label options this solution falls apart.

    Another option would be a custom HTML Webresource in an IFrame but this solution would loose the look and feel.

    Yet another option (prob not supported): [http://missdynamicscrm.blogspot.com/2015/06/create-button-in-crm-form-javascript.html] 

    • Proposed as answer by Ben Fishing Tuesday, October 13, 2015 9:05 PM
    Tuesday, October 13, 2015 5:48 PM