Hello,
Anyone else have any ideas ?
Thanks
Paul
Ken,
I want to monitor the Inbox of the Second Account. So that when New items
come in I can review them Programmatically to determine if they meet certain
criteria and deal with the Messages. I have the code that works fine when
only one inbox is open, but I need to be able to monitor a second inbox as
several of my users have 2 Inbox and what to run this code while having both
open.
Can you please review the code I've posted in this thread to determine if
their is a way to accomplish this ?
Thanks
Paul
"Ken Slovak - [MVP - Outlook]" <kenslovak@mvps.org> wrote in message
news:uVRCcRAwDHA.560@TK2MSFTNGP11.phx.gbl...
> If you want to select an alternate Inbox to move messages to you can
> find it using code similar to the code snippet I supplied. You can get
> your default Inbox using NameSpace.GetDefaultFolder(olFolderInbox).
> Each of those folders has an EntryID. You can assign a global
> MAPIFolder object to the alternate Inbox folder when you find it or
> you can store the EntryID of the folder and get it when you want using
> NameSpace.GetItemFromID(strEntryID) where strEntryID is the EntryID
> you stored.
>
> Once you have the alternate folder and the default one you can move
> items to the alternate folder.
>
> --
> Ken Slovak
> [MVP - Outlook]
> http://www.slovaktech.com
> Author: Absolute Beginners Guide to Microsoft Office Outlook 2003
> Reminder Manager, Extended Reminders, Attachment Options
> http://www.slovaktech.com/products.htm
>
> "Paul Schrader" <misc@katanasword.com> wrote in message
> news:ebdtKf2vDHA.3196@TK2MSFTNGP11.phx.gbl...
> > Ken,
> >
> > I'm not getting this I tried he results from your snippet of code
> and tried
> > to apply it but with no luck
> >
> > Can you show me what I need to change to make this work ? I run your
> code to
> > get the Id of the second mailbox and then qhat do I need to change
> in my
> > code to reference it ?
> >
> > Thanks
> > Paul
Dmitry Streblechenko - 16 Dec 2003 06:48 GMT
If you mean a second mailbox on Exchange, rertrieve it using
Namespace.GetSharedDefaultFolder() and use MAPIFolder.Items.ItemAdd event.
Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
> Hello,
>
[quoted text clipped - 52 lines]
> > > Thanks
> > > Paul
Paul Schrader - 16 Dec 2003 12:48 GMT
Hello,
Could you please prove a code example ?
Thanks
Paul
> If you mean a second mailbox on Exchange, rertrieve it using
> Namespace.GetSharedDefaultFolder() and use MAPIFolder.Items.ItemAdd event.
[quoted text clipped - 62 lines]
> > > > Thanks
> > > > Paul
Dmitry Streblechenko - 16 Dec 2003 17:49 GMT
Dim SecondInbox as Outlook.MAPIFolder
Dim with events SecondInboxItems as Outlook.Items
...
set Recip = Application.CreateRecipient("name of the second mailbox")
set SecondInbox = Application.Session.GetSharedDefaultFolder(Recip,
olFolderInbox)
set SecondInboxItems = SecondInbox.Items
...
sub SecondInboxItems_ItemAdd(Item)
MsgBox Item.Subject
end sub
Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
> Hello,
>
[quoted text clipped - 73 lines]
> > > > > Thanks
> > > > > Paul