They are used to perform some custom action before an event occurs.In this case, there is a flexibility of cancelling the event on some conditions so that the event that gets initiated will not occur.Item Unchecked Out – This occurs after un-checking an item in a list.Item Unchecking Out – This occurs while an item is being unchecked.Methods under the class SPItem Event Receiver handle item level events. Item Added – This occurs after a new item is added to a list. Item Adding – This occurs before an item is added to a list. Item Attachment Added – This occurs after an attachment is added to a list. Item Attachment Adding – This occurs while an attachment is being added to a list.Item Attachment Deleted – This occurs after an attachment is removed from an item.Field Updated – This occurs after a field is updated in a list.
Item Deleted – This occurs after an item is deleted from its list.
There are basically two types of event receivers: Synchronous and Asynchronous event receivers.
Synchronous event receivers are also known as ‘Before’ event receivers.
Method under the class SPEmail Email Event Receiver handles the event related to email. Email Received This occurs after an email message has arrived (to an email enabled list).
For the event receivers to receive an event, they should be bound to the corresponding objects. Using a feature Using a content type Using WSS object model In the feature, the file should be as follows.