Delete Document Library using SharePoint Power Shell Script


$SiteUrl = "http://SP:2010/sites/TestSite"
$web = Get-SPWeb $SiteUrl  
$library = $web.lists["Shared Documents"]
$library.AllowDeletion = $True
$library.update()
$library.Delete()

Comments

  1. very easy understood for basic level....

    ReplyDelete

Post a Comment

Popular posts from this blog

Convert List Collection to DataTable using C#

Difference Between Site Template and Site Definition

SharePoint 2010 Content Query Web Part