Dynamics CRM Undo
A simple and free solution that enables Undo and Redo functionality in CRM Forms.
What is it good for?
You’re working on a CRM form and updated some notes in the description of an open opportunity record. Before you save you realize you accidentally updated the amount, and you can’t remember what it was. What do you do?
Well, you probably have a few options:
- Close and re-open the opportunity form without saving the changes, losing the changes that you made but brining the amount back.
- Looking in the audit log (if it’s enabled) to get the latest amount. This may take a while and the data may not even be there.
- Guessing the amount / putting a random value in there. This one is probably not recommended…
Another option appears!
Well, if you have this free solution configured on the Opportunity form you have another option. Just Undo the changes, get the information you need, and then Redo the changes you need. With this solution you get the Ctrl+Z and Ctrl+Y shortcuts for Undo and Redo in any configured CRM form.
The solution is essentially a single self contained JavaScript with no external dependencies. It simply captures the data that is being changed as it changes to allow for undo and redo functionality.
Install and Configure
Configuring this addon is pretty simple:
- Download and Import the solution to your CRM Organisation.
- Open any form that you want to enable Undo functionality on with the Form Editor. Currently this only supports standard forms (Quick View and Mobile forms are not supported).
- Include the
guru_Undo.js
web resource as part of the form libraries. - Add an On Load event handler to call
Guru.Xrm.Undo.Init
. - Save and Publish.
- Check that it is working. Edit a record using the form you updated, try making a change, then hit Ctrl+Z and Ctrl+Y top see what happens.
If needed, it’s possible to add CommandBar/Ribbon buttons and call a Javascript method to getthe same effect. We’ve found that while Ribbon buttons tend to make sense, they seem to take up too much screen real estate with the CommandBar or are tucked away and un-intuitive to use. Either way, it’s very simple to add buttons to any entity form using the Visual Ribbon Editor or the Ribbon Workbench, both great tools to play around with the CommandBar / Ribbon buttons in CRM.
More Info
If this isn’t working, or you need more details, or you have some feedback, please just drop me a line and i’ll get back to you as soon as I can.