Office 365 将自动归档的里的文件移动到收件箱


1. 下载Microsoft Exchange Web Services Managed API 2.0并安装:

下载脚本 .ps1 file:

2. 打开Powershell并运行以下命令:

Set-ExecutionPolicy RemoteSigned
(if cx not able to run .ps1 file in step 6, try to change “Remotesigned” to “Bypass”)

$LiveCred = Get-Credential

$Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri -Credential $LiveCred -Authentication Basic -AllowRedirection

Import-PSSession $Session

3. 输入以下命令:

New-ManagementRoleAssignment –name:impersonationAssignmentName –Role:ApplicationImpersonation –User:"the e-mail address of admin account"

4. 输入以下命令

(前边的inbox是目标文件夹,也就是你自己的收件箱,后边的inbox是自动归档里的文件 夹)

5. 最后执行ps脚本开始移动:

.\Merge-MailboxFolder.ps1 –SourceMailbox -Sourcearchive -EWSurl -MergeFolderList $merge –Impersonate -username "admin account username" -password "admin account password" -domain "admin account domain"

Latest posts by Exchange中文站 (see all)
发布于: 浏览:6508 次