Powershell script: to find all content types in use across a sharepoint site collection


# Script to find all content types in use across

[System.Reflection.Assembly]::LoadWithPartialName("Microsoft.SharePoint") > $null

[System.Reflection.Assembly]::LoadWithPartialName("Microsoft.SharePoint.Publishing") > $null


$site = new-object Microsoft.SharePoint.SPSite ($url)

$contenttype = $site.rootweb.contenttypes["Document"]

ForEach ($web in $site.AllWebs) {

ForEach ($list in $web.Lists) {

if ($list.BaseTemplate -eq "DocumentLibrary") {

ForEach ($item in $list.Items) {

If ($item.ContentType.Name -ne $contenttype.Name) {

"" + $item.Url + "," + $item.ContentType.Name







To run the script in powershel, run: .\Filename.ps1 >> “C:\results.csv” – this will generate a CSV file with the result.

CamStudio Open Source Video Capture Utility

We had a problem trying to capture a clip from our cctv system the other day. Then, I discovered CamStudio, a little gem of an opensource utility that allows you to record all screen and audio activity on your computer and create industry-standard AVI video files or Streaming Flash videos (SWFs). This worked a treat and most of all it’s free of charge.

It’s well worth a pop if ever you need to capture a recording from a PC or across a network.

Download it today at: http://camstudio.org/

CorVu Integration with SharePoint 2007

My organisation uses CorVu for Business Intelligence. As a very heavy user of SharePoint technologies, we’d like to integrate the two together to facilitate greater information delivery and sharing.
So far, we have pulled CorVu based data into SharePoint using a Page Viewer Web Part and Web Deployment using HyperVu. This works fine but only provides a window into CorVu. Does anyone know if there are any specialist web parts or methods of truly integrating CorVu with SharePoint 2007.

Hello World Web Part Class Example

using System;
using System.Runtime.InteropServices;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Serialization;

using Microsoft.SharePoint;
using Microsoft.SharePoint.WebControls;
using Microsoft.SharePoint.WebPartPages;

namespace HelloWorldWebPart
public class WebPart1 : System.Web.UI.WebControls.WebParts.WebPart
private string displayText = “Hello World!”;
[WebBrowsable(true), Personalizable(true)]
public string DisplayText
get { return displayText; }
set { displayText = value; }
protected override void Render(System.Web.UI.HtmlTextWriter writer)