Failed to create feature receiver object from assembly

by rahul 9/23/2008 11:49:33 PM

I was learning to develop a feature in Sharepoint, and started with Inside Microsoft Windows SharePoint Services 3.0 by Tedd Pattison. It is a really awesome book. But this post is about a problem which really frustrated me and I ended up wasting some precious minutes struggling over a non-issue. I was in chapter 1, and I started copying/pasting the code to get a feel of how the features work. In the end, when I was supposed to see my code in action, I started getting this…

image

Now, you can’t blame a book when you are new to the technology, right? I thought I must have goofed up somewhere, or did something bad with my Sharepoint site… and just ended up making the problem worse. Anyway, in the end, I did something which I think I should have done first…

“READ THE ERROR CAREFULLY”

Failed to create feature receiver object from assembly "HelloWorld, Version=1.0.0.0, Culture=neutral, PublicKeyToken=e7bceefb86be0469", type "HelloWorld.FeatureReciever" for feature a790f1c4-0f27-4ba6-bace-1d7ff3a4ff29: System.ArgumentNullException: Value cannot be null.
Parameter name: type
   at System.Activator.CreateInstance(Type type, Boolean nonPublic)
   at System.Activator.CreateInstance(Type type)
   at Microsoft.SharePoint.Administration.SPFeatureDefinition.get_ReceiverObject()

Notice the typo above. FeatureReciever!!! This came in my project, because I copied/pasted it from the book Blushing.

ReceiverAssembly="HelloWorld, Version=1.0.0.0, Culture=neutral, PublicKeyToken=b59ad8f489c4a334" ReceiverClass="HelloWorld.FeatureReciever"

Just fixed the typo and everything was good. Hope you don’t do the same mistake I did. ALWAYS read the error SLOWLY and CAREFULLY. <preaching ends /> Bug

Until next time, Wave
Rahul


Quote of the day:
My grandmother started walking five miles a day when she was sixty. She's ninety-seven now, and we don't know where the hell she is. - Ellen DeGeneres


Currently rated 4.5 by 2 people

  • Currently 4.5/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Tags: ,

Sharepoint | Troubleshooting

Add comment


(Will show your Gravatar icon)  

  Country flag

biuquote
  • Comment
  • Preview
Loading



Calendar

<<  January 2009  >>
MoTuWeThFrSaSu
2930311234
567891011
12131415161718
19202122232425
2627282930311
2345678

View posts in large calendar

Recent comments

Disclaimer

The opinions expressed herein are my own personal opinions and do not represent my employer's view in anyway. We try our best to write good code, but none of the code here is tested on Production boxes. Feel free to use the code, BUT test it before you do so (in simple words... use it at your own risk)

© Copyright 2009

Sign in