Archive for October, 2008


What is this?

You can now download a CTP of Visual Studio 2010 and .NET 4.0 from Microsoft’s download center. Fetch the link in the bottom of this article to download!

“Microsoft Visual Studio 2010 and the .NET Framework 4.0 are the next generation development tools and platform for Windows Vista, the 2007 Office System, and the Web.”

Most people already know what this means, so I’m not going to bother talking about it in detail here – go try it for yourself, I know I will :-)


Have a good play!

Microsoft announces a new .NET logo

October 26th, 2008 by Tobias Zimmergren

Author: Tobias Zimmergren, SharePoint MVP

New .NET Logo!


I was quite fond of the old logo. Or rather, I didn’t mind it looking the way it did. However this new logo is far more cooler and in total sync with modern design/graphics!

I just thought that I’d share this with you so you won’t be surprised when you stumble upon the new logo later on :-)

Read more about it

I read about the new .NET logo in Scot Barnes blog, which you can do aswell if you’d like more background:

Have a good day!


CKS EBE – Comments Manager – Version

October 18th, 2008 by Tobias Zimmergren


Tobias Zimmergren


It’s getting late over here, but I ought to inform those of you using the EBE Comments Manager that there’s a new version out as of right now. It’s still a work-in-progress as a little private pet project of mine, so any suggestions and feedback are appreciated :)

For more information about the CKS EBE Comments Manager, check out this article!

If you want to skip the jidder, check out the tool directly: [Download]


  • Colorscales
    • Green: Approved Comments
    • Red: Rejected Comments
    • Yellow: Pending Comments
  • App.config
    • Settings file to put your default values for:
      • Blog URL
      • Comments List name
      • Trackback/Linkback List name (Coming soon)
  • Comments Management
    • Select any comment(s) by clicking the checkbox next to it
    • Use the AutoSelect filtering to automatically select all comments with a specific string in the body or title (Thanks to Johan Ljunggren for the proposal to put it in)
    • Approval Status changer
      • Change Approval Status to:
        • Approved
        • Pending
        • Rejected
  • All the stuff it did before, of course…

Usage / Introduction

  1. Go to the “Settings” tab and set the correct values (or do it in the App.config once and for all)
  2. On the “Comments Manager” tag, click “Fetch Comments” and wait for’em to load up (a few secs probably)
  3. Manage your comments a bit more easy



Summary & Download

This app is a very simple app which helps you to administer the comments for your  EBE blog. With the addition of approval status, you can easily approve, reject and set comments to pending.

This will of course be even more useful when the Web Service-interface is integrated, enabling you to do it from your client(s) :-)

You can download this lil’ tool here: [Download]

CKS EBE – Comments Manager

October 16th, 2008 by Tobias Zimmergren


    A new version of this tool can be downloaded [here]
    Read more about the new version [here]

I have been getting a few requests from people who’ve been getting quite a lot of spam in their Enhanced Blog Edition SharePoint blog, and who don’t currently have the ability to change any code or make adjustments. (They’ve got permissions to the system, but not to actually do anything like upgrade the assembly, add a nifty re-captcha validator or any other changes. They’re only allowed to do the “admin-stuff through the admin-interface”).

My quick and dirty solution was to provide them with a “Comments Manager” which basically is a Windows Application that will list all comments in the blog with a checkbox beside it. The “admin” can then check the desired (or, undesired..) blog comments and then kill them. This solution proved to be much faster than to do the same using the web browser using e.g. the tedious “Edit in datasheet view” option.

Note; This isn’t by far any cool application – it merely does what the few people want it to do, kill undesired comments with a better overview :)


This light-weight application will do the following:

  • List all comments
    • Comment Author
    • Trimmed Body
    • Background-coloring
      • Green for comments with status = “Approved”
      • Red for all other (Rejected and Pending)
  • Kill selected comments

Simple as that!

Comments Manager preview



Download the CKS:EBE Comments Manager v1.1.0.0

If you have ideas or comments, or if it simply doesn’t work – leave a comment!
Better yet, leave a comment anyway! :)

Future additions

If required by the people using this simple app – the future versions could include

  • Comment status change [Approval status]
  • Use Web Services to connect to your SP site instead
  • Track- and linkback manager
  • etc. etc.

Web Part Caching – A simple approach

October 7th, 2008 by Tobias Zimmergren

All kudos to Vince Rothwell who provided an awesome blogpost on SharePoint Caching and the CacheDependency object

This week I am tutoring a SharePoint 2007 development class over at Informator in Gothenburg, Sweden. Today we’ve been looking at Web Parts, creation of custom webparts and best practices for creating our custom solutions based on web parts.

I quickly coded up a sample which is caching items in a webpart – Huge server load is a major impact point for some organizations, making caching a strategically important choice if there’s much redundancy.

Anyway, you probably already know that it’s a good thing to cache your data once in a while if you’ve got heavy load and the data isn’t any “to-the-minute” critical information. So let’s get on with it..


Since people have been asking for a ‘simple sample’ of how to cache things in SharePoint – I thought that I would provide just that, a simple sample. For more in-depth information about caching and cachedependendies, check out Vince’s blog.

Check it out!

Web Part fetching items from a SPWeb object, looping all SPList objects and displaying the ItemCount property.

If there isn’t a cache object present, the iteration of the lists will be done immediately

If there is a cache object present, it will fetch the information from the cached object instead of iterating the lists, saving us some resources 

Code It!

This is the full code of the simple sample cache Web Part:

using System;
using System.Collections.Generic;
using System.Text;
using System.Web.UI;
using Microsoft.SharePoint;
using System.Web;
namespace Zimmergren.WebParts.SampleCachePart
    public class SimpleCache : System.Web.UI.WebControls.WebParts.WebPart
        protected override void Render(System.Web.UI.HtmlTextWriter writer)

            List<SPList> lists = new List<SPList>();
            string status = ""; 

            if (HttpRuntime.Cache["SimpleSampleCache"] == null)
                status = "The following items are <strong>NOT</strong> fetched from the cache<br/><br/>"; 

                SPWeb web = SPContext.Current.Web;
                foreach (SPList list in web.Lists)

                System.Web.Caching.CacheItemPriority.Default, null);
                status = "The following items <strong>ARE</strong> fetched from the cache!<br/><br/>";
                lists = (List<SPList>)HttpRuntime.Cache["SimpleSampleCache"];

            foreach (SPList l in lists)
                writer.WriteLine(l.Title + " – " + l.ItemCount + " items<br/>");

Summary & Download!

I always use the HttpRuntime or HttpContext objects to store and read my cached objects. You can of course use the built-in caching functionality of WSS 3.0 Web Parts if you feel that you have the need for it. However this approach works everytime, everywhere. Not just for Web Parts of course, but for any kind of ASP.NET hooked application.

You can download the sample project [here]

Thanks for tuning in,

I’m a Microsoft MVP

October 3rd, 2008 by Tobias Zimmergren

SharePoint MVP


I’ll keep this short, as I’m still rather stunned about this awesome news!

Yesterday after work I received some great news from Microsoft – I’ve been awarded the MVP award!

This means that we’re now two SharePoint MVP’s in Sweden. Göran Husman at HumanData and me!

Thanks to everyone for your support

About the Microsoft Most Valuable Professional Award

You can read about the award here:

“Microsoft Most Valuable Professionals (MVPs) are exceptional technical community leaders from around the world who are awarded for voluntarily sharing their high quality, real world expertise in offline and online technical communities. Microsoft MVPs are a highly select group of experts that represents the technical community’s best and brightest, and they share a deep commitment to community and a willingness to help others.” 

- Quoted from the Microsoft MVP site

Technorati-tags: , , ,