I am using a Powershell and CAML query to return items from a list. The list contains a "Group or People" field in which I have not seeing how to get the email and login information of the user. I assume I need to cast it to a SPUser object but have been unsuccessful so far. Anyone have an approach or snippet use?
$spQuery = New-Object Microsoft.SharePoint.SPQuery
$camlQuery = "<Where>...</Where>"
$spQuery.Query = $camlQuery;
$spListItems = $spList.GetItems($spQuery);
$spListItems | Sort-Object Title | ForEach-Object -Process {
$spListItem[4]; # this returns display name only
}