Rollup Field vs. Security Role

August 10, 2016

One of the professional benefits I gain from training Microsoft Dynamics CRM courses appears from time to time in the form of an innocent question from a student. A question which makes me stop for a moment and think… What would Mr. Spock answer to this? Here is one: Does a Rollup field calculation take the user’s privileges into account?  Let me demonstrate: a user has access to a Project records which contains the Total hours consumed. This is a Rollup field which sums up the related Activity Report records Total Hours field value. The user security Roles prevent...
no comments

Entity JavaScript Scaffold

July 23, 2016

In the last couple of years I have been writing more JavaScript code than Server side code in my Microsoft Dynamics CRM projects. Better UX, plethora of supporting JavaScript libraries, easier deployment and maintenance made me prefer a client side solutions. I usually create a JavaScript library for each entity requiring client side functionality (forms, command bars etc.).Over time, I have formed a JavaScript class scaffold. As this scaffold has improved my productivity when it comes to developing, debugging and maintaining client side code, I would like to share it here. Consistently using this or any other scaffold,...
no comments

Field Level Security – Update, Don’t Read

July 19, 2016

I always assumed Field Level Security privileges are somehow inclusive, meaning you can’t have Update privilege without Read. I was wrong. Defining the Field Security privileges lite this will prevent the profile users from reading the secured field value but will allow them to create with and update it. I can’t think of a business process which requires such behavior, but since Field Level Security apply to APIs as well as UI, it may be useful when external applications are required to update a secured value but are not allowed to retrieve it. 
no comments

Plug-in Configuration Manager Utility

July 15, 2016

Plug-in components often require external configuration settings. Maybe the Plug-in code consumes a web service which end point alternates between test and production environments or maybe you use the Plug-in configuration to turn logging on and off. Basically, any code setting which depend upon external resources is worth exporting to external configuration as it may prevent code re-compilation, additional testing etc. There are some common approaches to implement configuration settings for Plug-in components: Configuration file: each Plug-in instance consumes a configuration file Configuration record: each Plug-in instance executes a query to retrieve a designated Microsoft Dynamics CRM...
no comments

Dude, Where’s My Workflow?

April 27, 2016

There is no built view in Microsoft Dynamics CRM that shows the different solutions to which a component (such as Workflow Rule) is related. If you have many solutions, iterating through all of them can be exhausting and time consuming. The following query retrieve all solution which contain a Workflow Rule named testwf: <fetch version="1.0" mapping="logical">    <entity name="solution">        <attribute name="friendlyname"></attribute>        <link-entity name="solutioncomponent" from="solutionid" to="solutionid" >                      <link-entity name="workflow" from="workflowid" to="objectid">                <filter>                    <condition attribute="name" operator="eq" value="testwf"></condition>                       </filter>                                    </link-entity>        </link-entity>         </entity></fetch> The solutioncomponent entity binds elements such as Workflow Rule to Solutions. The solutionid attribute maps each solutioncomponent...
no comments

Generate Word Documents for Multiple Records

April 15, 2016

Version 2016 Word Templates is a useful feature with one noticeable limitation – when generating a Word Template based document, only one target record can be selected. In many business scenarios, users would like to select multiple records (maybe after executing an Advanced Find query) and generate relevant document in one or two clicks. In this post, I’ll demonstrate a customization based solution for generating Word Template based documents for multiple business records. In a following post, I’ll supply a more generic solution which can be applied to any template/entity. Here is the final result – after implementing the...
one comment

MSCRM 2016 Admin Utility – Personal Views Manager

April 11, 2016

You may have noticed that even under the almighty System Administrator Security Role, you can’t view (nor edit, share, assign or delete) other users Personal Views. Well, that’s what personal means. Via the application UI, only the view owner can manage it. This restriction can be troubling in some scenarios: A user who shared his Personal Views with other users or teams has left the organization and now no one can edit or delete these views which are irrelevant or just annoying A user has defined and shared a resources hungry Personal View which execution make the...

Customization Aware Web Resource – Part 3

April 4, 2016

In the previous post I demonstrated an implementation of the Customization Aware Web Resource approach using SOAP to retrieve metadata. In this post, I’ll demonstrate a similar implementation, this time using Web API.You can download an unmanaged solution containing the working sample code presented in this post. Note that this is a different solution version from the one made available in the previous post. Why should you use Web API instead of SOAP? Here are some of the reasons which importance rise as your implementation scales up: Reducing network traffic: compared to SOAP, REST requests are...

Customization Aware Web Resource – Part 2

March 23, 2016

In the previous post I described the Customization Aware Web Resource (CAWR) approach. This approach allows a dynamic reflection of certain customization changes in custom Microsoft Dynamics CRM client (Web Resource, Mobile app, Portal form etc.) as it query and apply metadata properties to relevant form controls. In this post, I’ll demonstrate an actual implementation of the CAWR approach using SOAP, for those of you who use Microsoft Dynamics CRM 2011 to 2015. In the next post, I’ll replace SOAP with Web API. You can download an unmanaged solution containing the working sample demonstrated in this post. This solution was exported from...

Customization Aware Web Resource – Part 1

March 11, 2016

Web Resource is one of the most powerful and versatile extension mechanism in Microsoft Dynamics CRM. It supplies an open canvas to draw custom UI, business logic and whole applications within entity forms, dashboards and stand alone pages. Coupled with the plethora of  free JavaScript libraries out there, you can easily provide your users with advanced solutions that work with Microsoft Dynamics CRM Data. In that sense, Web Resource can implement a custom client which can also be embedded into MSCRM elements. One concern regarding the investment in Web Resource development is the loss of dynamic customization capabilities, which...
one comment