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

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Service | Customer Service, Contact Center, Fie...
Suggested Answer

Save & Resolve custom button in the Case ribbon

(0) ShareShare
ReportReport
Posted on by 222

Hi community

I've got the requirement to create a custom button in the Case entity ribbon that a helpdesk agent can use to create and resolve a Case in one easy step.

The idea is that:

  • they will create the Case
  • complete the relevant fields
  • then click this custom button to Save & Resolve the case; the button needs to:
    • save the case
    • set a field (to indicate that it's = a first call resolution case)
    • move the business process flow stage to the Resolve stage
    • set the status reason to Problem Solved

I can get the last 3 button points done using a real-time workflow.

What I've tried to do, is using Ribbon Workbench to:

  • duplicate the Save button (and rename it Save & Resolve)
  • add an additional action to the existing Save action
    • it's with this additional action where I'm stuck
    • I know that the JScript function has changed with the Unified Interface
    • I tried using:

      • Library: $webresource:Service/CommandBarActions/ServiceCommandBarActions.js
      • Function: Mscrm.CommandBarActions.launchOnDemandWorkflowForm
      • Crm Parameter: SelectedEntityTypeCode
      • String Parameter: <guid of the real-time workflow>

        to call the real-time workflow, but it's not executing at all.

Can someone confirm if I'm using the correct Jscript library? Or even approach?

Thanks very much

Rean

  • Pankaj Gogoi Profile Picture
    3,177 on at

    Hi Reanm,

    Here is the path

    $webresource:Service/Incident/Ribbon/Incident_ribbon_library.js

    CrmService.IncidentRibbon.CommandBarActions.resolve

    You can modify the case resolution form to achieve your functionality.

    docs.microsoft.com/.../customer-service-hub-user-guide-modify-case-resolution-dialog

    Hope this helps

    Best Regards

    PG

  • reanm Profile Picture
    222 on at

    Hi Pankaj

    Thanks for your reply.

    I don't want to use the Case Resolution Dialog popup/quick create when resolving the case.

    I want to do it via a workflow.

    Thus the need for me to know what the Javascript webresource and function are to call an ondemand workflow in the UCI.

    Thanks again

    Rean

  • Pankaj Gogoi Profile Picture
    3,177 on at

    Hi,

    Please check this code for calling a workflow using Javascript.

    carldesouza.com/.../

    www.inogic.com/.../

    Hope this helps

    Best Regards

    PG

  • Suggested answer
    LeoAlt Profile Picture
    16,341 Moderator on at

    Hi Partner,

    Actually you don't need to modify the OOB save button JS function. You could add another new Command and add your custom JS function into a new web resource and call this function in new Command.

    pastedimage1596766834237v1.png

    And if you want to call workflow, you could use Web Api.

    https://chandanakommuri.wordpress.com/2019/01/25/execute-workflow-using-xrm-webapi-in-dynamics-crm-version-9-0/

    https://community.dynamics.com/crm/b/debajitcrm/posts/execute-workflow-using-xrm-webapi-in-dynamics-crm-version-9-0

    https://carldesouza.com/calling-a-dynamics-365-workflow-through-javascript/

    Best Regards,

    Leo

  • P. R. M Profile Picture
    739 on at

    Hi Reanm,

    I have implemented similar requirement. Please check below if it can helps you:

    crmtipsbyprm.wordpress.com/.../

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Women in Power Builds Momentum

Expanding mentorship, skilling, and AI innovation

Leaderboard > Service | Customer Service, Contact Center, Field Service, Guides

#1
Travis South Profile Picture

Travis South 37

#2
11manish Profile Picture

11manish 33 Super User 2026 Season 2

#3
Ayesha Wajahat Profile Picture

Ayesha Wajahat 18

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans