Prevent users from moving or deleting a folder

A

asoni12

How can I prevent users from deleting/moving a folder in Outlook/exchange
that is created by my application? On solution might be to create an outlook
plug-in and handle the event which is triggered before a folder is deleted. I
could find an Outlook Object Model event FolderRemove but it gets triggered
after the deletion of the folder. Any other idea?
 
K

Ken Slovak - [MVP - Outlook]

Version of Outlook?

For Outlook 2003 and earlier that's about it, the FolderRemove() event,
which is pretty useless for what you want. You'd have to respond to that
event and either re-create your folder or you'd have to hunt to find where
it was moved and try to move it back.

For Outlook 2007 you have the new Folder.BeforeFolderRemove() event which
can be cancelled.

If you subscribe to that event on your folder you get a MoveTo folder object
and a boolean Cancel parameter. If MoveTo is null the folder is being hard
deleted, otherwise it points to the new folder that will become the parent
of your folder. For soft deletes MoveTo points to Deleted Items.

Set Cancel to true to cancel the move.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top