O'Reilly logo

Microsoft Dynamics CRM 2011 Application Design by Mahender Pal

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Plugin to generate auto ID

Now let's write a plugin to generate an auto ID. Generating an auto ID in Microsoft CRM is a very common requirement. So we are going to write a generic plugin to generate an auto ID for any entity. We have created an Auto ID Setup entity, which we will use to create the entity record for which we need to generate an auto ID. We will specify the entity name and auto ID field name, and we will use this information in our plugin to set the auto ID.

First we will create an Auto ID Setup entity record that will provide an entity name, auto ID field, and start number for generating an issue ID. Create an auto ID setup record and enter the following information:

  • Name: new_issue
  • Auto ID Field: new_issuenumber
  • Start with: You can ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required