A Microsoft Outlook email forum. Outlook Banter

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.

Go Back   Home » Outlook Banter forum » Microsoft Outlook Email Newsgroups » Add-ins for Outlook
Site Map Home Register Authors List Search Today's Posts Mark Forums Read Web Partners

Intercepting ItemEvents



 
 
Thread Tools Search this Thread Display Modes
  #1  
Old August 19th 06, 12:44 PM posted to microsoft.public.outlook.program_addins
darshan tilak
external usenet poster
 
Posts: 1
Default Intercepting ItemEvents

I got a simple com addin for otulook working.
I need help me regarding how to intercept the ItemEvents : Add or
BeforeDelete.
I am aware of how to catch ApplicationEvents, but nowhere have i found an
example for ItemEvents.

A code example would be great....
Ads
  #2  
Old August 21st 06, 02:42 PM posted to microsoft.public.outlook.program_addins
Ken Slovak - [MVP - Outlook]
external usenet poster
 
Posts: 5,848
Default Intercepting ItemEvents

BeforeDelete only fires if the item is opened and you delete the item from
its File menu. Otherwise you won't ever get that event.

ItemAdd is an event of the Items collection of a MAPIFolder object. Since
you don't mention your language platform here's a sample in VBA.

Dim WithEvents colItems As Outlook.Items

' set colItems to the Items collection of the folder of interest. Then you
can handle the add event:

Private Sub colItems_ItemAdd(ByVal Item As Object)


--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Absolute Beginner's Guide to Microsoft Office Outlook 2003
Reminder Manager, Extended Reminders, Attachment Options
http://www.slovaktech.com/products.htm


"darshan tilak" wrote in message
. ..
I got a simple com addin for otulook working.
I need help me regarding how to intercept the ItemEvents : Add or
BeforeDelete.
I am aware of how to catch ApplicationEvents, but nowhere have i found an
example for ItemEvents.

A code example would be great....


 




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 04:50 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.Search Engine Friendly URLs by vBSEO 2.4.0
Copyright ©2004-2025 Outlook Banter.
The comments are property of their posters.