Plugins are custom classes that implement the IPlugin interface. The class can be written in any .NET framework-compliant language, such as Microsoft Visual C# or Microsoft Visual Basic .NET. The following screenshots illustrate how users can create a plugin project:
- Firstly, the user can create a new Class Library project, as shown in the following screenshot:
![](https://static.packt-cdn.com/products/9781788990226/graphics/assets/378b40af-5678-4629-946d-614171a6bae4.png)
Creating a plugin class project
- After the project is created, the user can add a new Class... item to the project. The new class would act as the plugin class:
![](https://static.packt-cdn.com/products/9781788990226/graphics/assets/c25b3519-ec93-4670-b3b1-a2506be1a0d7.png)
- Here's how we can add a new Class file to the solution:
![](https://static.packt-cdn.com/products/9781788990226/graphics/assets/23bd3c61-37b7-4046-a3c8-108f45496ce1.png)
Selecting the appropriate item type
- All the plugin projects must have a reference for the Microsoft.Xrm.Sdk and the Microsoft.Crm.Sdk.Proxy assemblies.
- If a person is writing a plugin for the first time, they must download the appropriate Dynamics SDK matching the target environment...