If I want to set calendar permissions for a list of users, and using the above script by Karl, could I do
foreach ($Person in Import-Csv "XXXXXXX.csv") {
$username = "*$($Person.username)*"
add-mailboxfolderpermission -identity $username:\calendar -user execassistant -accessrights reviewer
}
Also, where would i add a -whatif to the above in order to view the changes made before making the actual changes? After the add-mailboxfolderpermission line or after the foreach loop? Thanks