Hello. I am trying to do a simple powershell command to pull up access rights from a CSV list:
import-csv d:\scripts\accessrightsreport.csv | ForEach {Get-MailboxPermission -identity $_.email | where {$_.AccessRights -eq "FullAccess" -and $_.IsInherited -eq $false}} | Select User,{$_.AccessRights} | Export-CSV d:\scripts\MailboxReports\FullAccessReport.csv
The command seems to run, but at the end, I get:
Cannot process argument transformation on parameter 'Identity'. Cannot convert value "" to type
"Microsoft.Exchange.Configuration.Tasks.MailboxIdParameter". Error: "Parameter values of type
Microsoft.Exchange.Configuration.Tasks.MailboxIdParameter can't be empty. Specify a value, and try again.
Parameter name: identity"
+ CategoryInfo : InvalidData: (:) [Get-MailboxPermission], ParameterBindin...mationException
+ FullyQualifiedErrorId : ParameterArgumentTransformationError,Get-MailboxPermission
+ PSComputerName : outlook.office365.com
Where is the arguement I am leaving out?