⟩ How to use an event receiver?
Event receivers respond to events, thus used for something as canceling an action, e.g. deleting a document library by using the Cancel property. This would prevent users from deleting any documents if you wanted to maintain the data.