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

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

How to log plugin error to custom entity?

(0) ShareShare
ReportReport
Posted on by

I am working with CRM Online and would like to log plugin errors to a new Error entity.  I created the new Error entity where I can log the error message along with the plugin that caused the error.  I also created the plugin, in this particular case the plugin executes during an Acount Create event, it calls an external web service and expects a response back with some data.  If the web service call or any other part of the plugin fails, I want to log that error to the Error entity and also prevent the Account from creating.  This is where the problem arises.  I have the proper code to create a new record on the Error entity, but the problem is that by preventing the Create from happening, the transaction is rolled back, which means the Error entity record is also rolled back.  Does anyone know of a way around this?  Basically I need to create a new Error entity record AND prevent the Account from saving.

Thanks.

*This post is locked for comments

I have the same question (0)
  • Verified answer
    Aman Kothari Profile Picture
    on at

    This might help someone who want to log plugin errors to a new Error entity.
    here is the link
    https://crmdynamicsblog.wordpress.com/2016/01/09/create-log-in-plug-in-using-custom-entity/

    Thanks

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

#1
SA-08121319-0 Profile Picture

SA-08121319-0 4

#1
Calum MacFarlane Profile Picture

Calum MacFarlane 4

#3
Alex Fun Wei Jie Profile Picture

Alex Fun Wei Jie 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans