This sample creates a PowerShell function that lists files that are owned by the specified user and optionally match a mask. By default the function will match all users and files in the current directory.
Function Get-FilesByOwner([string] $userName = "*", [string] $fileMask = "*" ) {
#
# Get matching files owned by the specified user
#
Get-ChildItem *$fileMask* | ?{(Get-Acl $_ ).Owner -LIKE "*$userName*"} | Select FullName
}
PS C:\users\Phil> Get-FilesByOwner "Phils"
FullName
--------
C:\users\Phil\.android
C:\users\Phil\Contacts
C:\user\Phil\Desktop
C:\users\Phil\Documents
C:\users\Phil\Videos
C:\users\Phil\Dropbox
PS C:\users\Phil> Get-FilesByOwner "Phils" "Videos"
FullName
--------
C:\users\Phil\Videos