Search code examples
sharepoint-2007

sharepoint 2007 ItemEventReceiver not firing when called from code


I've developed a number of ItemEventReceivers that respond to the ItemUpdated event is called. When I edit an item in a list manually the event fires and all is right in my world, but when I write an application that calls this same list, gets the first item and calls item.Update() the Event Receiver does not fire. However, I know my application is working because when I check the item via SharePoint (the web front end) I can see that the item's modified date has changed.

Is there something I'm overlooking?


Solution

  • Yes, there is something you are overlooking! Are you absolutely sure the Event Receiver is not firing? No, you're not. Have you put in some debug statements? Err, no I didn't. Muppet!

    My event handlers are relying on settings from the configuration, which are there in the web.config in the web front end but not for the application.