0

I have a SharePoint webpart that creates an alert for a user, for a specific list item (in this case, a document set). I am adding the alert programmatically. The code executes without any errors, and I can see the alert when I click "Manage My Alerts" in SharePoint. The event type is "All", so alerts should get sent when someone adds a document to the document set. However, after the alert is created, and I add a document to the document set for which the alert was created, no email gets sent. I double-checked the email address and other settings for the alert, and everything looks OK. Additionally, I found the following entry in the event log:

Event manager error: Could not load file or assembly 'ListItemEventHandler, Version=1.0.0.1, Culture=neutral, PublicKeyToken=71a9581283b81d5f' or one of its dependencies. The system cannot find the file specified.

This entry was added five times. I assume this is related to the alert that was added. Does anyone know why the email notifications don't get sent?

PS: If I add the alert using "Alert Me" in SharePoint, the emails get sent.

  • Do you have any event receivers associated with the library? – Amal Hashim Jan 2 '15 at 16:31
  • No, I don't have any event receivers associated with the library. – Craig Moran Jan 2 '15 at 16:43
  • Do event receivers have to be associated with the library? None of the examples I read regarding programmatically adding events mention event receivers. – Craig Moran Jan 2 '15 at 17:35
  • We can have event receivers attached to list/libraries. And it enables us to handle ItemAdding, ItemAdded, etc. events. – Amal Hashim Jan 2 '15 at 17:37
  • I know what an event receiver is, but is it required in order to get the alert working? I just added it to my SharePoint solution, re-deployed it and re-ran the code that creates an alert, but I still do not receive email notifications. – Craig Moran Jan 2 '15 at 18:49

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.