Dynamics CRM Code Generator for Visual Studio

Visual Studio extension that will generated the early bound classes for for Microsoft Dynamics CRM 2011 / CRM 2013 / CRM 2015 / CRM 2016 / Dynamics 365.   Very Similar to what the CrmSvcUtil.exe does, which is also provided in the CRM Developer Toolkit as the “Generate Wrapper” function.

Benefits of using this tool over the standard tool

Control which entities to generate classes for
This will keep the size of the generated code to a minimum.  If you use the CrmSvcUtil.exe to generate, the code file will be 200,000 lines.   Compared ~1000 lines for each entity you select.

Customize the way the code is generated
You get a default T4 template for the code that gets generated.  This will give you full control how the code gets generated.

Built for Visual Studio
You never have to leave Visual Studio to regenerate the early bound classes.   All the configurations* are stored in the .SLN of the solution which allows you save them to Source Control.  This is very helpful if you are working with other developers.  (*username & password are stored in the .SUO file,  which typically isn’t checked into Source Control)

The Developer Toolkit does allow you to stay inside Visual Studio but it wont allow you change connection settings  while in Visual Studio.  You have to exit Visual Studio, delete your .SUO file then restart Visual Studio.

How to use

Install the VS extension –> https://crmcodegenerator.codeplex.com/releases

Add a template to your project


Regenerate Code by right click the template


Last edited Dec 11, 2016 at 2:40 PM by airrick2, version 15