NOTE: This is an example that requires using a custom workflow assembly that is not designed by ClickDimensions. Please do not contact ClickDimensions support for implementing this example. If you need assistance, a qualified CRM developer partner can assist you.
Want to send a survey to your customer when a case is resolved and have the response linked to the case in CRM? Here’s how: First, we’ll install a custom workflow assembly that will let us get a record’s ID so we can use it in a link. Then we’ll create the workflow that will send the link to the survey in an email.
Follow the instructions below to learn how to link a Posted Survey to a Case record in CRM. (This only works for Cases, not other entities.)
- Download and import the “GetRecordId” solution. (NOTE: For CRM On-Premise, after importing the solution, you will need to use the Plugin Registration tool to change the GetRecordId assembly to non-isolated mode. See the Microsoft CRM SDK for more info). This sample solution works with CRM 2011 on-premise. For other versions of CRM you will need to use the CRM SDK to write your own custom workflow assembly to get a record's ID and use it in a workflow, or find a pre-made one from the CRM community (ie, CodePlex, etc.) ClickDimensions does not support this download and provides it only as an example.
This sample solution contains a custom workflow activity that we’ll use later. (This is not available for CRM 4.0 or CRM 2013/2015/2016+, though there may be other solutions on Codeplex that will do the same thing.)
- Next, go to Settings > Processes and click “New” to create a new workflow process:
- Set the workflow scope to “Organization” and to start when the case’s record status changes:
- Add a “Check Condition” step to the workflow:
- Check that the Status Reason of the Case is “Problem Solved”:
- If you successfully imported the custom workflow activity in step 1, you’ll have an option to add a new custom step to the workflow, “GetRecordId”:
Add the “GetRecordId” step, and in the workflow designer, give it a simple name with no spaces such as GetId:
- Next, add a step to send an email (in this example, it’s a standard CRM email, not a ClickDimensions email):
Save your workflow. We need to get the URL of our survey before we compose the email.
- Open the ClickDimensions Survey web content record for your case satisfaction survey, and then click the “Design” button:
- In the Survey designer, click the Embed button to get the link to the survey. Copy the URL of the survey:
- Go back to your workflow and click the Set Properties button to compose the email. Add a hyperlink to the body of the email:
- The email body will now look like this:
- Place your cursor just after the link. We’re going to modify the link that is sent for the survey by adding two things: first a special parameter, and second, we’ll add the Record ID that the custom workflow step has generated:
After the survey link, type: ?p=1&_cld_incid=
NOTE: Make sure to remove any blank spaces between the link URL and the RecordId placeholder. Blank spaces will make the link break.
- Now, when a case is resolved, CRM will send an email with your survey link, and it will have the case ID as a parameter in the URL:
- When the customer completes the survey, the Posted Survey record will be automatically associated with the Case record in CRM:
Now you can kick off other workflows, such as an alert when a Posted Survey is associated to a case. Or you can use the same concepts to solve other business problems.
- This only works to link Posted Surveys to Case records. There is currently no method to link ClickDimensions surveys to other entities like Opportunities or your custom entities. This is something we are considering as a future enhancement.
- The custom workflow activity in step 1 can be used to get any record’s ID in a CRM workflow. For example, you can use this custom workflow step to get a Contact’s ID and save it to a custom field on the Contact record so you can use it to build links in ClickDimensions Email Templates.