newMail procedure and a public folder?

  • Thread starter Jeremy van Frank
  • Start date
J

Jeremy van Frank

The newMail Procedure that runs on the Application Object - I can get
it to run on my inbox but want to know if this can be modified to be
any folder, especially a public folder and if so how to code it.
Thanks
 
K

Ken Slovak - [MVP - Outlook]

It only runs on the Inbox, only runs at intervals and doesn't give you
a handle to the new item.

Use ItemAdd on the Items collection of that folder. Declare the items
collection WithEvents so you can trap ItemAdd. That way it works and
you get a handle to each new item put in that folder.
 
J

Jeremy van Frank

Ken, I'm still somewhat new to vba - trapping, withevents is still
kind of 'out there' - if you could please send sample code to give me
an idea of what you mean.

Thanks
 

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