André Krijnen

Archive for June, 2011

There was an error in the callback content and structure

by on Jun.16, 2011, under iis, Internet Information Services, SharePoint 2010, SharePoint Foundation

I ran today in this message in the SiteManager.aspx of SharePoint Server 2010: there was an error in the callback content and structure

So allright, I checked the search engines and did find some answers regarding this problem, but you know what. When restart your IIS server on your Web Front End the message doesn’t go away. Hmm odd, how could that be, well I figured out that it does a call back to another server, in my case it was one of the other SharePoint Servers in the farm. After resetting this server it removes the message and everything works fine again.

Leave a Comment :, , , , , more...

Powershell: Update all Document Libraries with MajorVersionLimit and MajorWithMinorVersionsLimit

by on Jun.15, 2011, under blog, Powershell, SharePoint 2010

I had to write a Powershell script to run thru all sites in a Web Application to enable Versioning. As well Major as Minor versions. With of course a limit on Major and Minor versions.

Next script should do the trick:

Add-PSSnapin Microsoft.SharePoint.PowerShell -erroraction SilentlyContinue
$siteURL = $args[0]
$site = Get-SPSite($siteURL)
foreach($web in $site.AllWebs) {
 Write-Host "Inspecting " $web.Title
 foreach ($list in $web.Lists) {
  if($list.BaseType -eq "DocumentLibrary") {
  Write-Host "Versioning enabled: " $list.EnableVersioning
  $host.UI.WriteLine()
  Write-Host "MinorVersioning Enabled: "  $list.EnableMinorVersions
  $host.UI.WriteLine()
  Write-Host "EnableModeration: " $list.EnableModeration
  $host.UI.WriteLine()
  Write-Host "Major Versions: " $list.MajorVersionLimit
  $host.UI.WriteLine()
  Write-Host "Minor Versions: " $list.MajorWithMinorVersionsLimit
  $host.UI.WriteLine()
  $list.EnableVersioning = $true
  $list.EnableMinorVersions = $true
  $list.MajorVersionLimit = 2
  $list.MajorWithMinorVersionsLimit = 5
  $list.Update()
  Write-Host $list.Title " is updated with MajorVersionLimit 2 and MajorwithMinorVersionsLimit = 5"
  }
 }
}

 

Leave a Comment :, , , , , , more...

Looking for something?

Use the form below to search the site:

Still not finding what you're looking for? Drop a comment on a post or contact us so we can take care of it!

Blogroll

A few highly recommended websites...