Category Archives: CRM Tips

Your own dev environment is the only real support guarantee when it comes to the open source solutions (aka Github-based).. #DynamicsConsulting

With any open source solution for Dynamics (aka Github-based), the only real support guarantee is to get the source code to your own dev environment and to build it there. Only then can you safely use that solution in production.. Don’t do that, and you’ll find yourself in trouble when the author abandons that solution and you will have to… Read More »

How to open a quick create form with JavaScript

There is a method in the Xrm.Utility namespace that we can use to open a quick create form: It turns out this method can produce a very vague error: And you won’t see much in the downloaded log file: Unhandled Exception: System.ServiceModel.FaultException`1[[Microsoft.Xrm.Sdk.OrganizationServiceFault, Microsoft.Xrm.Sdk, Version=, Culture=neutral, PublicKeyToken=31bf3856ad364e35]]: System.Web.HttpUnhandledException: Microsoft Dynamics CRM has experienced an error. Reference… Read More »

What do I need to know to become a Dynamics developer?

How would you answer if a .NET/JavaScript developer asked you: “what do I need to know to become a Dynamics developer?” There are, of course, books/bootcamps/courses covering this subject.. However, to put this in the context, imagine a project that’s been delivered by a consultant and that has to be supported by the internal full-time employees.… Read More »

Dynamics CRM: Adding a filter to the lookup

Here is a short code sample on how to add a pre-search filter to the lookup function onLoad() { Xrm.Page.getControl(…).addPreSearch(function () { addPreSearchFilter(); }); } function addPreSearchFilter() { var filter = “<filter type=’and’>” + “<condition attribute=’…’ operator=’not-null’/>” + “</filter>”; Xrm.Page.getControl(…).addCustomFilter(filter); }

Handling N:N relationships in Dynamics CRM plugins

Here is a quick and dirty example of how a plugin could be created to handle N:N associations. A plugin like this would need to be registered for the “Associate” message of “any” entity: using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using Microsoft.Xrm.Sdk.Client; using Microsoft.Xrm.Sdk; public void Execute(IServiceProvider serviceProvider) {   IPluginExecutionContext context… Read More »