We have a SharePoint list that has item level security. (It is a custom link list - not a library) I need to list out the permissions for each item. I've been trying to use powershell to do this but have not gotten very far yet.
I have this so far:
$site = new-object Microsoft.SharePoint.SPSite("http://mysite")
$web = $site.OpenWeb("mysubsite")
$list = $web.Lists["mylist"]
$items = $list.Items #Get list item collection
$ItemsCount = $items.Count #Get list items total count
for($Counter = $ItemsCount-1; $Counter -ge 0; $Counter--)
{
$Item = $Items[$Counter] #Get list item via index
Write-Host $Item["Category"] ", " $Item["Title"] ", " $Item["Ref#"]
}
$web.dispose()
$Site.dispose()
I tried using a foreach instead of the for loop but did not have any luck getting any results - like so
foreach ($item in $list) { write-host code here }
Anyway, now I need to enumerate the permissions but I'm at a loss for how to go about it. Also, I want to save this to a csv file - which I think I can figure out from other examples I've seen.
I'm really struggling with finding some good documentation sources for Powershell. I can't find much of anything that documents the methods (or are these properties?). For example above I have $site.OpenWeb, $web.Lists, $list.Items; what other methods are there that I can apply against site, web, list, or list item?
Nancy Forbes









