I'm trying to run a command on all my users in Teams.
below is how far I got.
Get-CsUserPolicyAssignment -PolicyType TeamsMeetingPolicy -Identity user@contoso.com
PolicyType PolicyName PolicySource
---------- ---------- ------------
TeamsMeetingPolicy Cloud Recording On {Cloud Recording On}
what is the best way to create a loop on this and have this output instead like below
User PolicyType PolicyName PolicySource
---- ---------- ---------- ------------
user@contoso.com TeamsMeetingPolicy Cloud Recording On {Cloud Recording On}
user1@contoso.com TeamsMeetingPolicy Cloud Recording On {Cloud Recording Off}
user2@contoso.com TeamsMeetingPolicy Cloud Recording On {Cloud Recording On}
below is how far I got.
Get-CsUserPolicyAssignment -PolicyType TeamsMeetingPolicy -Identity user@contoso.com
PolicyType PolicyName PolicySource
---------- ---------- ------------
TeamsMeetingPolicy Cloud Recording On {Cloud Recording On}
what is the best way to create a loop on this and have this output instead like below
User PolicyType PolicyName PolicySource
---- ---------- ---------- ------------
user@contoso.com TeamsMeetingPolicy Cloud Recording On {Cloud Recording On}
user1@contoso.com TeamsMeetingPolicy Cloud Recording On {Cloud Recording Off}
user2@contoso.com TeamsMeetingPolicy Cloud Recording On {Cloud Recording On}