Overview: CKSDev provides mutiple SPI for SharePoint, the Event Receiver SPI is very useful in saving me tome writing all the plumbing code.
Problem: While updating a custom list using my event receicer I am re-firing the event receiver for the item.
Initial Hypothesis: Disable the event firing as shown in this post. This post applies to MOSS and the methods have been depreciated in SP2010.
Resolution: Disable the EventFiring
this.EventFiringEnabled = false;
// Perform update
this.EventFiringEnabled = true;
Problem: While updating a custom list using my event receicer I am re-firing the event receiver for the item.
Initial Hypothesis: Disable the event firing as shown in this post. This post applies to MOSS and the methods have been depreciated in SP2010.
Resolution: Disable the EventFiring
this.EventFiringEnabled = false;
// Perform update
this.EventFiringEnabled = true;
Paul -
ReplyDeleteThere is also the matter of asynchronous vs. synchronous execution of the event handling code. This post shows it more detail - Managing ItemUpdating and ItemUpdated Events:
http://www.simple-talk.com/dotnet/.net-tools/managing-itemupdating-and-itemupdated-events-firing-twice-in-a-sharepoint-item-event-receiver/