Monday, March 7, 2016

How to get specific sub sites Using Get-SPWeb object

$WepApp = "http://peakfinderspowe/"
$site = Get-SPSite $WepApp
$array = @("Title of the First Site", "Title of the Second Site")
$filteredWebs = $site | Get-SPWeb | ? {$array -contains $_.Title}

No comments:

Post a Comment