Hi Nigel,
I've been working with an email received event handlers (and a couple of other event handlers) for some time on a project, but we're not deploying them via features, we're using a code based method of deployment at the moment. Will probably be moving to feature based deployment shortly, so I can't comment on the correctness of your feature deployment infrastructure. But, the particular error you're getting ... ---- Event Type: Error Event Source: Windows SharePoint Services 3 Event Category: General Event ID: 6644 Date: 25/07/2008 Time: 10:15:02 User: N/A Computer: EVERSHEDS Description: Event manager error: Could not load type 'Eversheds.SharePoint.Portal.EventHandlers.KnowledgeSubmissions.EmailHandler ' from assembly 'Eversheds.SharePoint.Portal.EventHandlers, Version=1.0.0.0, Culture=neutral, PublicKeyToken=9f525b76b9e4fb66'. For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp. ---- .. sounds much more like you don't have the appropriate event handler assembly into the GAC ... If it's not in the GAC, you can use GACUTIL from the command line to load it, or you can simply drag and drop the DLL into the GAC, most commonly found at C:\Windows\assembly on a standard Windows installation. I wonder also if you are loading the assembly into the GAC, whether you might be incrementing the version of the assembly with automatically with each build, which would mean that the full name by which SharePoint would be trying to create the object (i.e. 1.0.0.0) is not the version of the current assembly? Hope those may help ... Cheers, Trevor From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Witherdin, Nigel Sent: Friday, 25 July 2008 7:31 PM To: [email protected] Subject: [OzMOSS] Overriding SPEmailReceiver for Email Enabled libraries Hi All, Has anyone ever had any luck overriding the SPEmailReceiver class for a document library? I have coded a simple one, but am having problems getting it to fire. ---- namespace Eversheds.SharePoint.Portal.EventHandlers.KnowledgeSubmissions { public class EmailHandler : SPEmailEventReceiver { public override void EmailReceived(SPList list, Microsoft.SharePoint.Utilities.SPEmailMessage emailMessage, string receiverData) { base.EmailReceived(list, emailMessage, receiverData); SPListItem listItem = list.Items.Add(); listItem["Title"] = emailMessage.Headers["Subject"]; listItem["Body"] = emailMessage.HtmlBody; foreach (SPEmailHeader hdr in emailMessage.Headers) { string name = hdr.Name; string value = hdr.Value; } } } } ---- I have tried binding it to my list with a <Receivers> element in my feature's elements.xml: ---- <!-- Email Event Receiver for the Knowledge Submissions Library --> <Receivers ListTemplateOwner="EE2458B8-4594-4bef-A9F9-29D9F3D3A632" ListTemplateId="101"> <Receiver> <Name>EmailHandler</Name> <Type>EmailReceived</Type> <SequenceNumber>10000</SequenceNumber> <Assembly>Eversheds.SharePoint.Portal.EventHandlers, Version=1.0.0.0, Culture=neutral, PublicKeyToken=9f525b76b9e4fb66</Assembly> <Class>Eversheds.SharePoint.Portal.EventHandlers.KnowledgeSubmissions.EmailH andler</Class> </Receiver> </Receivers> ---- and also in code within my feature event receiver with a SPList.call: ---- //Set the item rec'd event handler against Knowledge Items library string assm = "Eversheds.SharePoint.Portal.EventHandlers, Version=1.0.0.0, Culture=neutral, PublicKeyToken=9f525b76b9e4fb66"; string nsp = "Eversheds.SharePoint.Portal.EventHandlers.KnowledgeSubmissions.ItemHandler" ; web.Lists["Knowledge Items"].EventReceivers.Add(SPEventReceiverType.EmailReceived, assm, nsp); //Set the email rec'd event handler against Knowledge Items library nsp = "Eversheds.SharePoint.Portal.EventHandlers.KnowledgeSubmissions.EmailHandler "; web.Lists["Knowledge Items"].EventReceivers.Add(SPEventReceiverType.EmailReceived, assm, nsp); ---- but everytime I expect it to fire, I get the follow app event log error: ---- Event Type: Error Event Source: Windows SharePoint Services 3 Event Category: General Event ID: 6644 Date: 25/07/2008 Time: 10:15:02 User: N/A Computer: EVERSHEDS Description: Event manager error: Could not load type 'Eversheds.SharePoint.Portal.EventHandlers.KnowledgeSubmissions.EmailHandler ' from assembly 'Eversheds.SharePoint.Portal.EventHandlers, Version=1.0.0.0, Culture=neutral, PublicKeyToken=9f525b76b9e4fb66'. For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp. ---- I am fairly certain my type information is correct (have checked it via Reflector), but just to make certain, I changed the code in my "ItemHandler" event handler (which has been working fine) so that its namespace had the email receiver in it - and got the same type error! This is driving me crazy - I expected the ItemReceiver to fire when emails were delivered to the library, but this doesn't happen (why not?!?), so I thought I would be able to use this event handler to handle the stuff I want to do to email - but no luck! If anyone can see where I am going wrong, or could provide some code snippets for a handler that actually works (binding and handler please) I would really appreciate it. Cheers, Nigel Witherdin Senior Support Analyst Eversheds Direct Dial: +44 (0) 84 549 754 17 Mobile: +44 (0) 7738 553256 www.eversheds.com <http://www.eversheds.com/> _____ From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Aaron Saikovski Sent: 25 July 2008 00:23 To: [email protected] Subject: RE: [OzMOSS] Infrastructure update for WSS and MOSS And please pay attention to the installation instructions J Kind Regards, Aaron Saikovski Aaron Saikovski | Senior Consultant | Microsoft Services | Microsoft Pty Australia | t: +61 2 8817 9280 | m: +61 410 480 971 | e: [EMAIL PROTECTED] | a: 1 Epping Road, North Ryde, NSW 2113 Disclaimer: This email may contain confidential information. If you are not named on the addressee list, please take no action in relation to this email, do not open any attachment, and please contact the sender (details above) immediately. Information in this email is provided in good faith. If you are a customer of Microsoft, please refer to the terms and conditions which cover the provision of support and consulting services to you/your organization. If you are not corresponding in the course of, or in connection with a Microsoft contract or programme with its own terms and conditions, please note that no liability is accepted by Microsoft for the contents of this mail. From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Ed Richard Sent: Thursday, 24 July 2008 10:07 PM To: [email protected] Subject: [OzMOSS] Infrastructure update for WSS and MOSS Just making sure everyone is aware of this important update. I haven't seen it being mentioned in this list. http://blogs.msdn.com/sharepoint/archive/2008/07/15/announcing-availability- of-infrastructure-updates.aspx Ed Richard MOSSIG Board Member M: 04 06385559 P: 03 97623155 E: <mailto:[EMAIL PROTECTED]> [EMAIL PROTECTED] W: www.mossig.net B: EdOnOffice <http://edonoffice.blogspot.com/> MOSSIG_Sidebar.jpg Microsoft Office System Special Interest Group (MOSSIG) - Melbourne Please consider the environment before printing this email. ------------------------------------------------------------------- OzMOSS.com - to unsubscribe from this list, send a message back to the list with 'unsubscribe' as the subject. Powered by mailenable.com ------------------------------------------------------------------- OzMOSS.com - to unsubscribe from this list, send a message back to the list with 'unsubscribe' as the subject. Powered by mailenable.com ********* This email is sent for and on behalf of Eversheds LLP ********* This email is sent for and on behalf of Eversheds LLP which is a limited liability partnership, registered in England and Wales, registered number OC304065. Registered office One Wood Street, London, EC2V 7WS. Registered VAT number GB820704559. A list of the members' names and their professional qualifications is available for inspection at the above office. Regulated by the Solicitors Regulation Authority (see www.sra.org.uk <http://www.sra.org.uk/> ). Confidentiality: This email and its attachments are intended for the above named only and may be confidential. If they have come to you in error you must take no action based on them, nor must you copy or show them to anyone; please reply to this email and highlight the error. ************* [ www.eversheds.com <http://www.eversheds.com/> ] ************* ------------------------------------------------------------------- OzMOSS.com - to unsubscribe from this list, send a message back to the list with 'unsubscribe' as the subject. Powered by mailenable.com ------------------------------------------------------------------- OzMOSS.com - to unsubscribe from this list, send a message back to the list with 'unsubscribe' as the subject. Powered by mailenable.com
<<image001.jpg>>
