DeleteContents from mailbox with no confirmation (exchange 2010 and powershell)
我使用以下命令删除邮箱的内容,但它仍然提示我确认。有没有办法不提示我。
1
|
Search–Mailbox -id“UserName” –DeleteContent -Confirm:$false
|
停止提示的方法是使用 -Force 参数(如果 cmdlet 支持的话)。
将 -confirm 设置为 $false 仅表示”如果需要,请提示我。”将 -confirm 设置为 $true 表示”每次都提示我。”
简单的事情就是通过 /Library/Mail/v2/MailData 并删除带有名称的文件
Envelope 然后所有内容将从邮件应用程序中删除
似乎有一个语法错误 -confirm like -DeleteContent is a SwitchParameter 这意味着你只需要省略它。
1
|
Search–Mailbox -id“UserName” –DeleteContent
|
- 谢谢,我不知道。
来源:https://www.codenong.com/5952413/