Thursday, January 22, 2009

Create Your Own CRM 4.0 Plugin Helper

Microsoft Dynamics CRM 4.0

Sometimes I get tired of writing the same code over and over again. For example, when I retrieve a Dynamic Entity and set the ColumnSet to AllColumns, its the same thing over and over again.


TargetRetrieveDynamic(EntityName, EntityId)
RetrieveRequest(Target, ColumnSet, ReturnDynamicEntities)
RetrieveResponse(Request)
DynamicEntity = (DynamicEntity)retrievedEntity


Also it is the same thing getting the entityId from the context. Although this does depend on what message, pipeline, and whether it is a pre or post event, the code is always the same.

And how about those messy Query Expressions, Condition Expressions, Filter Expressions, Retrieve Multiple, and so on.

Wouldn't it be nice to build a class that will handle all of those things for you with minimal effort on your part. I have been creating plugins for about a year now and I have by no means mastered the craft as of yet but I believe I have done it enough to know that the CRM SDK is not nice when it comes to carpal tunnel. This is why your poor fingers need a break every now and then. That is why I have created the Ultimate CRM SDK Plugin Helper Class 1.0. I say 1.0 because it is still a work in progress. i.e. look for updates on my blog.


Link to the CRM SDK Plugin Helper Class.

No comments:

Post a Comment