Change Outlook Meetings En Masse
I had my mailbox migrated to a new domain today. One of the side effects of this was that for silly reason, a large number of my meetings now had a prefix of Copy: added to the subject of the meeting.
Which annoyed the hell out of me.
Now I could go ahead and remove all the extra information one by one - but that is tedious annoying and against my automation principles.
So starting with this post Retrieve all-day appointments in Outlook with PowerShell and this one as well Create Outlook Appointments from PowerShell, I have managed to change all the outlook appointments that have the extra text in the subject line with the following lines of code
$olApp = New-Object -COM Outlook.Application
$namespace = $olApp.GetNamespace("MAPI")
$fldCalendar = $namespace.GetDefaultFolder(9)
$items = $fldCalendar.Items
$copies = $items | ? {$_.Subject -like "Copy:*" }
$copies | % {
$newsubject = ($_.Subject).Trim("Copy: ")
$_.Subject = $newsubject
$_.Save()
}
Before
After
Gotta Love PowerShell!!