![]() |
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 created a com add-in that fires an event when a new mail arrives. This is the code: Private WithEvents objNS As Outlook.NameSpace Private WithEvents colItems As Outlook.Items Private Sub Application_Startup() Set objNS = Application.GetNamespace("MAPI") 'NameSpace Object Set colItems = objNS.GetDefaultFolder(olFolderInbox).Items .... End Sub Private Sub colItems_ItemAdd(ByVal Item As Object) Code to handle incoming mail End Sub Usually, this code does the work but some times it doesn't. When it stop working the event doesn't fire for all incoming mails. I fix it by closing and reopen the outlook. When the outlook is reopen it loads the add-in.Some times I need to restart the computer. I tried to solve this problem by cretaing a schedule task for a bat file that contain a regsvr32 command for this dll but it doesn't solve the problem. I don't think that it's a problem of code but I think that it's a problem of the outlook that unload the add-in without a logical reason. I'll glad to get help for this problem. Thanks, David |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
locking the time zone for an event | Jetlagged&shoeless | Outlook - Calandaring | 1 | October 6th 06 12:03 AM |
Work part time and need my free/busy time to reflect that in Outl. | allensxs3 | Outlook - Calandaring | 1 | July 13th 06 02:14 PM |
work week calendar I want to see only my strat time to end time? | Audrey Racine | Outlook - Calandaring | 1 | May 11th 06 04:55 PM |
How do I remove a time from an all day event? | Gran2ty | Outlook - Calandaring | 1 | May 10th 06 05:08 PM |
How to enter work start time PM end time AM | wmllmw | Outlook - Calandaring | 5 | April 15th 06 06:23 PM |