web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

Auto number

(0) ShareShare
ReportReport
Posted on by 2,665

Hi,

I am working on creating a copy of the existing records by creating 1:N relationship(self referencing relationship) with the incident entity itself. Then I am mapping the fields that I want to show up in the copy(duplicate) of the record. But the problem is with the auto number of the record. I have a plugin that creates auto numbers on creation of record. But when I create duplicate of the record, the autonumber plugin does not get triggered and a system generated Case Number gets created instead(ex: CAS-123-xxxxx).

So, how do I get my auto number plugin to trigger even when a duplicate is created from the original record?

Thanks for any help.

*This post is locked for comments

I have the same question (0)
  • Community Member Profile Picture
    on at

    Hi Roxanna,

    My name is Andres Guzman, I'm glad to help you

    I think your autonumber plugin is a third party deployment.

    I recommended you to contact the developer to this code to request this info.

    Regards,

  • crmprogrammer2013 Profile Picture
    2,665 on at

    It is not a third party deployment.

    I am just wondering, if I have to make changes to the plugin or do I have to trigger the same plugin when the user clicks on the button to create a copy of the record.

    Thanks

  • Mahadeo Matre Profile Picture
    17,021 on at

    On which event you registered auto numbering plugin on case?

    CRM plugins will be automatically triggered based on events.

    If you registered plugin on save.. then it should trigger onSave.. might be you need to debug that plugin and see what logic in preventing to create your custom number.

  • crmprogrammer2013 Profile Picture
    2,665 on at

    It is registered on Create Message. Obviously, even the duplicate record creation has to trigger the plugin. But it's not doing that! On a side note, I never had good luck with debugging plugins!

  • Verified answer
    Mahadeo Matre Profile Picture
    17,021 on at

    Are you using any filter attributes for this plugin, if you are using it might be problem.. when you are creating copy might be one of the filter attribute you are missing to set.

    Also.. here are details on how to debug plugin using plugin registration tool..

    msdn.microsoft.com/.../gg328574.aspx

  • crmprogrammer2013 Profile Picture
    2,665 on at

    Thanks Mahadeo,

    I suspect the problem is with the system generated field mapping on 'Case Title' field in the self referencing relationship I created. This Case Title field is used in the plugin to display the custom auto number. I tried to delete that mapping but it threw this error.

    'Could not delete field map. One or more of the field maps could not be deleted because they are being used by the Microsoft Dynamics CRM platform'.

    Then I tried to null that field through javascript on form load but the script not getting triggered too!

  • crmprogrammer2013 Profile Picture
    2,665 on at

    bump..

  • Shailaja Mahajan Profile Picture
    250 on at

    Hello Roxanna,

    I would suggest to create a service request with Microsoft Support for further investigation.  

    Thank you.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Meet the Microsoft Dynamics 365 Contact Center Champions

We are thrilled to have these Champions in our Community!

Congratulations to the March Top 10 Community Leaders

These are the community rock stars!

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

#1
JS-09031509-0 Profile Picture

JS-09031509-0 3

#2
AS-17030037-0 Profile Picture

AS-17030037-0 2

#2
Mark Eckert Profile Picture

Mark Eckert 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans