An Engineers Notebook

Suppress confirmations in PowerShell

Using Remove-MailboxPermission as an example we need to add “-confirm $false” to suppress the Are you sure prompt.

Remove-MailboxPermission -Identity "Mailbox Name" -user [email protected] -AccessRights FullAccess -InheritanceType All -confirm:$false

Leave a Reply

Your email address will not be published.