InvalidPluginExecutionException dialog does not sh

2019-08-05 10:48发布

I have a Plugin on the Creation, Updating, and Deletion of the OpportunityProduct entity in the CRM 2011. I want to through exception on the success of some operations, means want to display dialog. It is working fine for Update and Delete. But it is not working fine for the Creation of OpportunityProduct, it is not throwing exception in the dialog. It is showing Exception: “An error has occurred, Try this action again. If the problem continues, check the Microsoft Dynamics CRM Community for solution or contact your organization’s Microsoft Dynamics CRM Administrator. Finally, you can contact Microsoft Support.

  1. Message : Create
  2. Primary Entity : opportunityproduct
  3. Action: Pre-Operation
  4. Execution Mode: Synchronous

1条回答
贼婆χ
2楼-- · 2019-08-05 11:16

I think this is an internal issue that relates to how CRM treats compound entities such as opportunity product. To verify this behavior you should put breakpoint in your code and inspect the context depth and parent context to understand if the create event is indeed a child process or the opportunity. If so you might be able to re-register the plug-in the opportunity and try to somehow throw the error from there.

查看更多
登录 后发表回答