Reply to Message

View discussion in a popup

Replying to:
Razz007
Contributor
Contributor

Exactly what I was looking for... thanks.

&{foreach($vm in Get-VM){
  Get-VIPermission -Entity $vm |  Select -ExcludeProperty EntityId,ExtensionData,Uid -Property @{N="VM";E={$vm.Name}},*}} | Export-Csv C:\temp\outputfile.csv -NoTypeInformation -UseCulture

Output as follows for all VMs

VMEntityRolePrincipalPropagateIsGroup
LABBMC001DatacentersAdminAdministratorsTRUETRUE
LABBMC001DatacentersAdminCBS\Domain AdminsTRUETRUE

Reply
0 Kudos