Here the quick solution to clean up/delete SharePoint list items that save a days lot if cleanup required. Manual efforts would take a lot so…
Leave a CommentHome » list
Tag: list
PowerShell script to delete files from list and output list of deleted file
Published December 30, 2014 by Imthiaz Rafiq
Delete files listed in CSV the PowerShell script will read and clean it up from physical location.
PowerShell
1 2 3 4 5 6 7 8 9 |
$Termed_Users = "C:\Data\Termed_Users.csv" $Home_Folders = "X:" $UserList = Import-Csv $Termed_Users $UserList | ForEach-Object { $ID = $_.ID $User_Home = $Home_Folders + "\" + $_.ID Remove-Item -recurse -force $User_Home -erroraction silentlycontinue } |