Friday, May 3, 2013

Powershell - Delete list from Sharepoint site



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

$site=new-Object Microsoft.SharePoint.SPSite("http://siteurl/sites/test/")

$web=$site.OpenWeb()

$list=$web.Lists["ListName"]

$list.Delete()

No comments:

Post a Comment