Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 272
  • Last Modified:

Removing Outlook 2010 Calendars Users have added

In Outlook, users are able to ADD Calendars to their Calendar view  (via Right click MY CALENDARS then ADD CALENDARS).

Rarely but occasionally, we have the need to delete and re-create a user's mailbox and when we do so, these previously created links no longer work.

We've sent instructions to the users ad-nauseum on how to remove and then re-add these entries which they ignore, forget about and then submit new tickets to the Help Desk that their links don't work.

Is there any way (GP, Batch Program, Login Script, ANYTHING) where we can remove individual (or all) added calendars centrally?

Saw reference to deleting the NK2 file (doable in the login script) which does not exist in Outlook 2010, but haven't found anything else to lead me in the right direction in either Outlook or Exchange (2010).

Any help appreciated.
0
FarrellFritz
Asked:
FarrellFritz
  • 2
1 Solution
 
luconstaCommented:
Try the following script but TEST IT THOROUGHLY before mass deployment!!!!

Is a PowerShell script that will delete all the calendars beneath the calendar folder:

$outlook = new-object -com Outlook.Application
$namespace = $outlook.GetNamespace("MAPI")
$folder = $namespace.GetDefaultFolder("olFolderCalendar")
$folders=$folder.folders.count
$i=1
For ($i; $i -le $folders; $i++) { 
$fldName = $folder.folders.item(1).name
write-host $fldName
$folder.folders.item(1).delete()
}

Open in new window


Hope this will help...
0
 
FarrellFritzAuthor Commented:
THANKS... will try.  Not so familiar with PowerShell.  Is there a way to execute this like in a (DOS) batch file that we could put in the login script?
0
 
luconstaCommented:
Yes, could be deployed by GPO, but it requires at least Windows 2008 and Windows 7 - more details here: Using Group Policy to Deploy a Windows PowerShell Logon Script
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now