This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<# | |
.SYNOPSIS | |
Loops through the recycle bin and output a csv string. | |
Uses PNP Powershell. | |
.EXAMPLE | |
-URL:'https://<tenant>.sharepoint.com/sites/<siteCollection>' -Stage:First -Path:.\FirstRecycleBin.csv | |
-URL:'https://<tenant>.sharepoint.com/sites/<siteCollection>' -Stage:First -Path:.\FirstRecycleBin.csv -RowLimit:200000 | |
#> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Create an array of computers to do work against | |
$Computers = “computer01”,”computer02”,”computer03”,”computer04”,”computer05” | |
# Create an empty array that we'll use later | |
$RunspaceCollection = @() | |
# This is the array we want to ultimately add our information to | |
[Collections.Arraylist]$qwinstaResults = @() | |
# Create a Runspace Pool with a minimum and maximum number of run spaces. (http://msdn.microsoft.com/en-us/library/windows/desktop/dd324626(v=vs.85).aspx) |