Kruthika Reddy Kruthika Reddy - 7 months ago 70
PowerShell Question

" list of files and subfoldes owner information" with powershelll script

I can see some in this link""

I tried but the examples but neither of them was working for me.Thanku!!!


This will do it

get-childitem c:\users\usera\documents -Recurse | foreach{
    $f = $_.FullName
    $o = Get-Acl $f | Select Owner -ExpandProperty Owner
    Write-Output "$f is owned by $o"