javascriptdynamics-365crm-ribbon-workbench

Ribbon Workbench adding PrimaryControl param breaks form


When adding a Crm Parameter to a Custom JavaScript Action in Ribbon Workbench, I get the following when in the Unified Interface. Works in the legacy client.

enter image description here

Just adding PrimaryControl as a Crm Parameter to my JavaScript action. enter image description here


Solution

  • Solution was to add both the CommandProperties and PrimaryControl as Crm Parameters to the JavaScript action using the following order:

    enter image description here

    And making sure to pass there parameters into the function.

    function HandleSyncTask(commandProperties, primaryControl) { /* more logic */ }