Redemption Newmail Not always firing?

R

Ryan

I'm using office 2003 and Redemption's NewMail event to capture
newmail before Outlooks Desktop Alert responds. During the event if
an email has a certain subject I delete it. The problem is it seems
to be firing everytime I am not viewing the inbox contents. If I'm
viewing the contents of the inbox and several emails get delivered at
one time it seems to only fire once. There fore if several emails
come in at the same time that should be deleted not all of them do.
Has anybody had any problems with this?
 
D

Dmitry Streblechenko \(MVP\)

Hmmm... If you have OutlookSpy, can you try the following:
1. Click IMsgStore
2. Go to the IMsgStore::Advise tab
3. Retrieve multiple new messages

How many fnevNewMail notifications do you get?

Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
 
R

Ryan

Dmitry Thanks for you time,

I'm using Outlook 2003 with Exchange.
I downloaded and registered a copy of your OutlookSpy and did the
following. I created script to send multiple emails to myself
using Redemptions SafeMailItem. Each mail's subject just had a
identifier and a incremented number to easily identify them. With in
the NewMail from a Redemption.MAPIUtils object if the subject had the
identifier it would then move it to the trash. I then as you
requested watched the IMsgStore::Advise Tab.

I first sent 17 messages and only 5 where caught by the NewMail event
and only 5 fnevNewMail notifcations showed up when the 17 messages
where delivered (All at one time). Then tried the same thing about
but this time in the NewMail event I logged ever mailItem to a file to
see when it was firing. I tried 8 messages. All again arrived at the
same time. Only 3 where caught and logged in the NewMail event and 3
fnevNewMail notifcations showed. Both times it only caught the last 5
and last 3 messages that where delivered.

Why is the event only firing sometimes? Is there a way around this?
When I loggin in the morning I get about 20 emails immediately. My
program will never be able to process all emails with the specific
subject. I can try using the Inbox's ItemAdd event but then the
Desktop Alert Window will show up when the email arrives and I'm
trying to avoid this because these emails are not supposed to be read
by the individual. I found the only why I could stop the Desktop
Alert from showing up was to trap it in your Redemption's NewMail
event and move it to the Trash where then I can process it. Any
idea's or suggestions? Thanks again for all you help.
 
R

Ryan Hubbard

Just a note. I ran the same program but with the ItemAdd event on the
Inbox folder. I sent numerous emails 5+ and watched for the fnevNewMail
event. Only 3 fnevNewMail events where logged just like before but the
ItemAdd event fired for every email not just for the fnevNewMail events.

The NewMail event in Redemption only seems to fire for every fnevNewMail
event. Is this correct? Anyway do you know of anyway to bypass the
Outlook 2003 Desktop Alert Dialog for incoming mail. Currenlty the only
way I have found is to use Redemptions NewMail and move it to another
folder but using ItemAdd event does not stop the Desktop Alert.

Thanks for all you help.

*** Sent via Devdex http://www.devdex.com ***
Don't just participate in USENET...get rewarded for it!
 
D

Dmitry Streblechenko \(MVP\)

Yes, NewMail in Redemption fires for each fnevNewMail. Note however that
fnevNewMail can include multiple new mail notifications, in this case
Redemption will fire NewMail for each item in fnevNewMail.

Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
 

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