“Need to start a transaction before commit” Fault Exception in crm 2011
Hi we were getting this error on our plugin on post update of an entity.
The plugin was using Associate message to associate one entity record to other.
If the records were already associated, it was throwing “duplicate key” error, so we were catching that fault exception and then were updating few other records in our plugin. However just after the execution of our plugin, we were getting the CRM’s Error dialog box having a error log file mentioning the above error.
Later we realized that once a Fault Exception is thrown then the execution of the plugin is no longer in transaction. We can’t catch the faualt exception and still be in transaction. This post clarified that.
http://social.microsoft.com/Forums/en-US/crmdevelopment/thread/ca1301ca-cef9-4940-9cb4-e968641199f6
Hope it helps !
Filed under: CRM, CRM 2011, Microsoft Dynamics CRM Tagged: CRM 2011, Microsoft Dynamics CRM
This was originally posted here.

Like
Report
*This post is locked for comments