One of my customers asked me why can’t she edit multiple Tasks (bulk edit) in Advanced Find results grid, while it is certainly possible in any other Tasks grid.
I was not aware of the this limitation and tested it myself. It seems that the Edit command is disabled for all Activity types in Advanced Find results grid when trying bulk edit.
What is the purpose of this limitation? Don’t really know, but here a quick workaround:
Instead of searching for Tasks (or any other type of Activity), select Activities as the Advanced Find query entity and add a condition on the Activity Type column to match the required type.
For some reason, bulk edit is enabled for this query results.
The downside of this workaround is that this query is limited to the general Activity attributes. If you need to query a custom Task attribute, you can save the query as a personal view, access it in any Tasks grid and bulk edit away.
I have been using the Plugin Registration Tool to debug Plugins for sometime now and it has turned out to be a real time saver as it let’s you run and debug your code without having to trigger application events. This shortens debug cycles and allows Plugins debugging by multiple developers simultaneously without halting the W3WP process.
I have just found out the Plugin Registration Tool can also help debug Custom Workflow Activities as well. Since this feature is currently not documented in the SDK or any other official literature, this post will guide you through.
Please note, currently this feature is not functioning well in Online deployments, hope MS will fix this soon.
In order to debug a Custom Workflow Activity, follow these steps:
- Activate the Plugin Registration Tool as an administrator. Make sure you are using the latest Plugin Registration Tool version from the latest SDK package.
- Register your Custom Workflow Activity using the Plugin Registration Tool.
- Create a Workflow Rule which reference your Custom Workflow Activity.
- If you don’t have the Profiler installed, click the ‘Install Profiler’ button in the inner menu. After it finishes installing, the Plugin Registration Tool shows the ‘Uninstall Profiler Button’ and a new item ‘Plug-in Profiler’ is added to the registered components
- Click the ‘Plug-in Profiler’ item. Note the ‘Profile Workflow’ button appearing in the inner top menu
- Click the ‘Profile Workflow’ button to open the Profile Setting window. From the Workflow picklist, select the Workflow Rule which contains the Custom Workflow Activity requires debugging
- Check the Custom Workflow Activity requires debugging. Select ‘Persist to Entity’ radio option and click ‘OK’. Copy the value In the Persistence Key field to your clipboard
- Notice the Profiled item added under the Plug-in Profiler root
- Go to your CRM organization and trigger the relevant Workflow. In my example, this is a manual Workflow rule.
- Go to Settings –> Extensions –> Plug-in Profiles. If you can’t locate it, refresh the window.
- Open the relevant Plug-in Profile record, make sure the Persistence Key matches the one you have copied earlier
- Click the Serialized Profile tab and copy the value in the Serialized Profile filed
- Create a new text file and copy the Serialized Profile string into it. Save the file
- Go Back to the Plugin Registration Tool, select the profile created earlier and click the Debug button in the inner toolbar
- In the opened Debug window, select the newly created text file in the the Profile Location field and the Custom Workflow Activity assembly in the Workflow Activity field
- Go to Visual Studio, where the Custom Workflow Activity project is opened. Compile your code and locate the Custom Workflow Activity assembly and PDB file in the “…\Program Files\Microsoft Dynamics CRM\Server\bin\assembly” folder
- Attach the debugger to the Plugin Registration Tool Process. Put some break point in your code and click the Start Execution button in the Plugin Registration Tool Debug Window.
You are done. The Breakpoint should be hit and from now on you can edit your code and debug locally against the Plugin Registration Tool.
Now go get productive.
December 2012 Service Update features two new interesting capabilities:
- Custom Activities support for Microsoft Dynamics CRM Online
- Executing multiple requests with the ExecuteMultipleRequest class
These capabilities allow important improvements to the Asynchronous Batch Process Pattern solution described here.
So what’s new?
The lack of Custom Activities support in Online deployment required the usage of a Plugin component to perform the Target Records query and implementing the Action Workflow to each result record.
With December 2012 Service Update Custom Activities support for Microsoft Dynamics CRM Online, a Custom Activity can now replace the Plugin component. This implementation renders the Asynchronous Batch Process Pattern solution simple and robust.
The new ExecuteMultipleRequest class allows sending a bulk of requests to the Organization service in one request, instead of a stream of separate requests. This feature is now used in the Asynchronous Batch Process Pattern solution In order to apply the Action Workflow Rule to multiple Target Records in a single request and to improve the solution’s performance.
I will make the new and improved solution available for download soon.