![]() |
If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Search this Thread | Display Modes |
#1
|
|||
|
|||
![]()
Hi,
I have used "FolderSwitch","BeforeItemCopy" Event Handlers and got the events fired in corresponding situations successfully. But like that I cannot use "ItemEvents_10_BeforeDeleteEventHandler" for preventing the deletion of certain mails.Whether deletion of mails can be prevented.Can this be done through code (I am using C#.NET VSTO2005) ? Regards RAMS |
Ads |
#2
|
|||
|
|||
![]()
Are you saying the event isn't firing at all, or that setting ref Cancel ==
true doesn't work? That event will only fire if you are handling events for the item and the user deletes the open item from the File, Delete menu item. Otherwise it will not fire. It's not really that useful for that reason. -- Ken Slovak [MVP - Outlook] http://www.slovaktech.com Author: Professional Programming Outlook 2007 Reminder Manager, Extended Reminders, Attachment Options http://www.slovaktech.com/products.htm "RAMS" wrote in message ... Hi, I have used "FolderSwitch","BeforeItemCopy" Event Handlers and got the events fired in corresponding situations successfully. But like that I cannot use "ItemEvents_10_BeforeDeleteEventHandler" for preventing the deletion of certain mails.Whether deletion of mails can be prevented.Can this be done through code (I am using C#.NET VSTO2005) ? Regards RAMS |
#3
|
|||
|
|||
![]()
Hi Ken,
{ explr =app.ActiveExplorer(); } .. .. { explr.BeforeItemPaste += new ExplorerEvents_10_BeforeItemPasteEventHandler(Befo reItemPaste); } like this I have used the BeforeItemPaste event handler and got fired.But like that I cant able to initialize "explr.BeforeDeleteEvent += new Microsoft.Office.Interop.Outlook.ItemEvents_10_Bef oreDeleteEventHandler(BeforeDelete);". thanks and regards RAMS "Ken Slovak - [MVP - Outlook]" wrote: Are you saying the event isn't firing at all, or that setting ref Cancel == true doesn't work? That event will only fire if you are handling events for the item and the user deletes the open item from the File, Delete menu item. Otherwise it will not fire. It's not really that useful for that reason. -- Ken Slovak [MVP - Outlook] http://www.slovaktech.com Author: Professional Programming Outlook 2007 Reminder Manager, Extended Reminders, Attachment Options http://www.slovaktech.com/products.htm "RAMS" wrote in message ... Hi, I have used "FolderSwitch","BeforeItemCopy" Event Handlers and got the events fired in corresponding situations successfully. But like that I cannot use "ItemEvents_10_BeforeDeleteEventHandler" for preventing the deletion of certain mails.Whether deletion of mails can be prevented.Can this be done through code (I am using C#.NET VSTO2005) ? Regards RAMS |
#4
|
|||
|
|||
![]()
Did you read what I said?
If you look in the Object Browser there is no Explorer.BeforeItemDelete event, so how could you subscribe to it. That event is only there for Inspector's. From my previous post: That event will only fire if you are handling events for the item and the user deletes the open item from the File, Delete menu item. Otherwise it will not fire. It's not really that useful for that reason. -- Ken Slovak [MVP - Outlook] http://www.slovaktech.com Author: Professional Programming Outlook 2007 Reminder Manager, Extended Reminders, Attachment Options http://www.slovaktech.com/products.htm "RAMS" wrote in message ... Hi Ken, { explr =app.ActiveExplorer(); } . . { explr.BeforeItemPaste += new ExplorerEvents_10_BeforeItemPasteEventHandler(Befo reItemPaste); } like this I have used the BeforeItemPaste event handler and got fired.But like that I cant able to initialize "explr.BeforeDeleteEvent += new Microsoft.Office.Interop.Outlook.ItemEvents_10_Bef oreDeleteEventHandler(BeforeDelete);". thanks and regards RAMS |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Event handler when a mail from the inbox is selected | Cherry | Add-ins for Outlook | 1 | February 9th 08 01:10 PM |
AdvancedSearchComplete event handler | nana | Outlook and VBA | 3 | June 30th 07 06:10 AM |
event handler for changes to TO CC and BCC properties of mailitem | epsilon_9 | Outlook and VBA | 3 | January 15th 07 03:14 PM |
Outlook VSTO Appointment Item Delete Event | lg | Add-ins for Outlook | 0 | July 31st 06 10:35 AM |
Handling Task Item Delete Event | AtulSureka | Outlook - Using Forms | 0 | January 24th 06 10:25 AM |