Archive for June 14, 2012

SPD WebPart Definition Code

Using SharePoint Designer, users can update WebPart properties directly via the code pane. Now, if this is a requirement for you, you’ll notice that when editing a custom version three WebPart (System.Web.UI.WebControls.WebParts.WebPart) that the properties are displayed as attributes of the WebPart element:

<webpart:test_webpart runat="server" CustomProperty="custom value"></webpart:test_webpart>

I’ve trimmed the above to make it more readable, the real element would be far longer and all on one line.

To make it easier for users to update properties via SPD and to move the properties to their own child elements, one option available is to make a few changes to your WebPart.

  • Change the WebPart to inherit from the version 2 class – Microsoft.SharePoint.WebPartPages.WebPart
  • Add the SupportsAttributeMarkup(false) attribute to the WebPart class
  • For the property you want displayed as a child element, ensure the property attribute used for storage is WebPartStorage(Storage.Shared) and not Personalizable(PersonalizationScope.Shared). The storage type used is not important.

For example:
Read more


Today, we have a non SharePoint related post to start June with.

I’ve been using various time tracking systems over the past while and have had varied success with them. Some I’ve loved certain features but hated others parts of their offering. I’ve been on the lookout for a system that “just does it” and lets me get on with the important stuff, like actually working 🙂

Recently, I found a free, yes free, online time tracking and billing system which ticks all of my boxes. OK, I said free, well it’s only free if you are happy to have a single user. As I’m a freelancer this suits me perfectly. Not that it’s that expensive if you do need to scale up. Two users is a mere £6.5/month with additional users costing about £3 each.

What is it? It’s from a company called Paymo and their website is
Read more


Get every new post delivered to your Inbox

Join other followers: