Events on Adding/Deleting Fields from Content types

One of the things that’s driven me nuts in SharePoint 2007 is that there are no events to capture when a Field is added to a Content Type. There is an OnAdded event – which sometimes gets used to save Custom Properties of the field (though I prefer Gunnar Peipman’s approach)

Well, no more! In SharePoint 2010, there are now OnAddingToContentType() and OnDeletingFromContentType() methods. We can override this in our custom fields, and this lets us do lots of useful things – like register event handlers, add workflows, or set properties on the content type, which are things that I’ve wanted to do a few times now. So, good news!

Events on Adding/Deleting Fields from Content types

Silverlight in SharePoint 'Hello World' demo

I’ve not used Silverlight, and I though it might be interesting to try the Silverlight Web Part from SharePoint 2010, so I came up with a little ‘hello world’ project. Using Silverlight, I wanted to:

  • Query a SharePoint List for data
  • Display that data

Not exactly complicated stuff, but I figured it would be a start. I decided to query a Picture Library, and display the pictures in my web part, changing the displayed image every few seconds. All of this is very achievable with JavaScript or jQuery and the Content Query Web Part (as some sort of variant on the CQTWP I built), so I thought this would be a good comparison. Continue reading “Silverlight in SharePoint 'Hello World' demo”

Silverlight in SharePoint 'Hello World' demo