Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

InvalidPluginExecutionException no longer returning a "nice" user message in CRM 365 9.1.0.2842 when resolving cases (incident entity)

(0) ShareShare
ReportReport
Posted on by 216

A customer has a few validators they wanted to use to check various conditions when resolving incidents. These validations are handled by a plugin, which simply throws an InvalidPluginExecutionException exception with the appropriate message. This USED to simply show this message on the screen for the user.

Unfortunately, something seems to have been changed in the CRM, and now the message is just this:

06166.Capture.PNG

Also, the detail log contains ONLY this line and nothing else:

The operation was aborted due to ISV code.

This really feels... wrong, on many levels. The log file not containing any relevant information, the lack of a clear message to the user. Is this some kind of recent MS change? Is there some kind of new way to "throw" nice, business-related errors to the user from a plugin?

*This post is locked for comments

  • Mikael Suokas Profile Picture
    5 on at
    RE: InvalidPluginExecutionException no longer returning a "nice" user message in CRM 365 9.1.0.2842 when resolving cases (incident entity)

    I realize this is an old question, but I ran into this just today, so this may be helpful to someone out there.

    I just made a plugin validating fields during incident resolution, and had this exact same problem: the message from InvalidPluginExecutionException would not show up to the user, only the class name of the plugin. In my case the InvalidPluginExecutionException would be wrapped in another InvalidPluginExecutionException in my top-level exception handler. When I added an explicit catch in the top level handler to just pass pass InvalidPluginExecutionException through, I would get the clear message in the UI:

               catch (InvalidPluginExecutionException e)

               {

                   throw;

               }

  • MateuszBender Profile Picture
    216 on at
    RE: InvalidPluginExecutionException no longer returning a "nice" user message in CRM 365 9.1.0.2842 when resolving cases (incident entity)

    [quote user="Goutam Das"]

    May be  the error is  coming from another plugin or different code  where the error does not handled properly.

    This error is also coming when you have multiple plugin and the message does not overwrited. So disabled all associated plugin with the and only enable the plugin which you are expecting to show the message

    How can you sure that the the message should populate? Do you have any trace log? did you tried to debug?

    Try to debug and also put some trace log in your plugin code.[/quote]

    This is DEFINITELY not a problem with my code.

    a) It used to work just fine and there were no updates.
    b) I know exactly which two lines of code that are responsible: a simple if (condition) statement followed by a throw new exception statement; commenting these out makes the plugin continue without issues (but this isn't what the customer wants, obviously).
    c) The same code can be applied not just to incident closure, but also incident updates - it seems to work fine then; it's only when it's applied to incident updates when resolving cases - that's when the errors are suppressed.
    d) Put some trace? Isn't that what the detailed log should be for, in CRM Online? As I outlined in my original post - the log file is almost completely empty, except for a rather useless line...

  • gdas Profile Picture
    50,091 Moderator on at
    RE: InvalidPluginExecutionException no longer returning a "nice" user message in CRM 365 9.1.0.2842 when resolving cases (incident entity)

    May be  the error is  coming from another plugin or different code  where the error does not handled properly.

    This error is also coming when you have multiple plugin and the message does not overwrited. So disabled all associated plugin with the and only enable the plugin which you are expecting to show the message

    How can you sure that the the message should populate? Do you have any trace log? did you tried to debug?

    Try to debug and also put some trace log in your plugin code.

  • Suggested answer
    Radu Chiribelea Profile Picture
    6,667 on at
    RE: InvalidPluginExecutionException no longer returning a "nice" user message in CRM 365 9.1.0.2842 when resolving cases (incident entity)

    I would open a support case with Microsoft and check with them if this isn't a known bug. This happened in past builds as well so it wouldn't be a surprise if this is a regression.

    Regards,

    Radu

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

🌸 Community Spring Festival 2025 Challenge Winners! 🌸

Congratulations to all our community participants!

Adis Hodzic – Community Spotlight

We are honored to recognize Adis Hodzic as our May 2025 Community…

Kudos to the April Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard > Microsoft Dynamics CRM (Archived)

#1
Mohamed Amine Mahmoudi Profile Picture

Mohamed Amine Mahmoudi 83 Super User 2025 Season 1

#2
Community Member Profile Picture

Community Member 52

#3
Victor Onyebuchi Profile Picture

Victor Onyebuchi 6

Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans