kwizcom banner advertisement

Find Who Created a List or Library in SharePoint using PowerShell

If you want to find out who has created a SharePoint site, list or library: Sorry! There is no way from SharePoint user Interface!! You can't get "Created By" or "Created On" values anywhere. 

But PowerShell is our rescuer! Lets find who has created a SharePoint list using PowerShell:

Find Who Created a List or Library using PowerShell
Add-PSSnapin Microsoft.SharePoint.PowerShell -ErrorAction SilentlyContinue

#Get the List and Web
$web = Get-SPWeb "http://portal.crescent.com/sites/Sales"
$list = $web.lists["Sales Docs"]

#Get Creator and Created date of the given List
Write-host "List Created by:"$List.Author
Write-host "List Created on:"$List.Created

PowerShell to Find Who Created a File in SharePoint:
Add-PSSnapin Microsoft.SharePoint.Powershell -ErrorAction SilentlyContinue

#variables
$SiteURL = "http://intranet.crescent.com/Sales"
$FileURL = "/sales/Shared%20Documents/Compliance%20Process.xlsx" #Relative URL

#Get the Web & File
$Web = Get-SPWeb -Identity $SiteURL
$File = $Web.GetFile($FileURL)

If($File.Exists)
{
    Write-Host "Created By: " $File.Author
    Write-Host "Modified On: " $File.TimeLastModified
    Write-Host "Modified By: " $File.ModifiedBy
    Write-Host "Created On: " $File.TimeCreated
}
else
{
    Write-Host "File doesn't exist!"
}


Related post: Determine who created a list view in SharePoint
Find Who Created a List or Library in SharePoint using PowerShell Find Who Created a List or Library in SharePoint using PowerShell Reviewed by Salaudeen Rajack on March 02, 2015 Rating: 5

No comments:

Please Login and comment to get your questions answered!

Powered by Blogger.