I just want to verify my understanding of how this works. Would the two following scripts have the same result?
Code:
foreach ($mailbox in get-mailbox)
{
Set-Mailbox -Identity $mailbox -ManagedFolderMailboxPolicy "30 Day Retention"
}
Code:
get-mailbox | ForEach-Object -process
{
Set-Mailbox -Identity $_ -ManagedFolderMailboxPolicy "30 Day Retention"
}