Skip to main content

Notifications

Microsoft Dynamics CRM (Archived)

Plugin Exception Code -2147220956 "An unexpected error occurred from ISV code"

Posted on by Microsoft Employee

Hi,

I have a plugin registered against a custom entity in CRM to set the stageid of an incident via the regarding Entity . This is done using this snippet of code(I have stripped out the code for "Some ID").

 regardingEntity.Attributes.Add(
                    "stageid",
                    "Some ID");

                service.Update(regardingEntity);


I have profiled the code and the parameters I am passing in to the Arributes.Add() are correct. I have also changed the field I am updating on the regarding entity to a simple text field to ensure that the plugin code has access to the regarding entity and all seems to work ok. It appears that something else is happening behind the scenes in CRM and all I am getting back from the exception logs is this generic error code

-2147220956 "An unexpected error occurred from ISV code"

I was wondering if anyone has any insight into what this error code could mean. I have ruled out a number of potential problems around Security roles, Owning Users of the entities etc..


 Regards,

*This post is locked for comments

  • ashlega Profile Picture
    ashlega 34,475 on at
    RE: Plugin Exception Code -2147220956 "An unexpected error occurred from ISV code"

    If you have process entities there, you might just want to set stage id differently:

    blogs.msdn.microsoft.com/.../best-practices-for-automating-business-process-stage-progression-in-dynamics-365

  • Suggested answer
    RaviKashyap Profile Picture
    RaviKashyap 55,410 on at
    RE: Plugin Exception Code -2147220956 "An unexpected error occurred from ISV code"

    Hi Colm,

    Can you check if you have any other process, business rule [Entity], plugins etc which could trigger after this plugin?

    There is a possibility that the error is occuring from some other place. Best way is to enable/ disable and see where it starts working.

    Hope this helps.

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

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Community AMA December 12th

Join us as we continue to demystify the Dynamics 365 Contact Center

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,240 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,149 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans