PowerShell Script to Copy/Replace items from one list to another list

Ok guys, I did work on this script for couple of hours and came up with working solution, basically this script will copy/replace items from one SharePoint List to another SharePoint List. Tip: Save the Source list as templace without Content and create desination list with source template and disable any workflows that are associated… Read More »

PowerShell – Update HREF – Rich Text Field

I do have a very strange requirement that i need to change the hyperlink of a item in list (like upload documents link to another library) but unfortunately I cannot edit the item as the link if formed dynamically in workflow, so to update the link I need to use PowerShell. And below is the… Read More »

Delete users from User Information List

Delete Users from User information List. Get the user details from previous script matching the criteria and use excel to import from text and get the CSV #This script will remove users specified in the CSV. $CSVFile = Import-CSV D:\Indra\Users.CSV # Change the path Add-PSSnapin Microsoft.SharePoint.PowerShell -EA SilentlyContinue #Get all site collections $Sites = Get-SPSite… Read More »

Get Users matching a Domain

Get Users matching a Domain in User Information List. # Run with SharePoint 2010 Management Shell $webUrl = “http://SharePoint” $web = Get-SPWeb $webUrl #$list = $web.Lists[“User Information List”] $user = Get-SPUser -web $web -Limit All | Where-Object {$_.UserLogin -Like “*AD\*”} | Format-Table -Autosize | Out-File D:\Indra\Users.txt Write-Host Done. Change the URL and out-put file path… Read More »

Extract Solution Files from SharePoint

So the situation is we cannot find the solution files which was deployed long ago and the best, quick and easy way to get all WSP files from SharePoint is below script. The below script will copy all the deployed solution files to the folder specified. Note: Create the folder before executing the command. And… Read More »

PowerShell – Update Item value without triggering workflow

I faced strange requirement from my client , they want to update the item value but workflow should not run (its already completed) , so what is the easiest way to do the obvious, answer is PowerShell!! Below is the script to get the job done. $spWeb = Get-SPWeb -Identity http://SharePoint #Replace with your URL… Read More »