Results 1 to 2 of 2

Thread: Events in MS Outlook

  1. #1

    Thread Starter
    Hyperactive Member vbzero's Avatar
    Join Date
    Aug 2000
    Location
    Vienna
    Posts
    347

    Events in MS Outlook

    How can an external program check, if MS Outlook has received mail?

    thx, vbzero

  2. #2
    Fanatic Member InvisibleDuncan's Avatar
    Join Date
    May 2001
    Location
    Eating jam.
    Posts
    819
    The sample code must be placed in a class module, and the Initialize_handler routine must be called before the event procedure can be called by Microsoft Outlook.
    VB Code:
    1. Dim WithEvents myOlApp As Outlook.Application
    2.  
    3. Sub Initialize_handler()
    4.     Set myOlApp = CreateObject("Outlook.Application")
    5. End Sub
    6.  
    7. Private Sub myOlApp_NewMail()
    8.     MsgBox "New mail has arrived, you lucky thing"
    9. End Sub
    Indecisiveness is the key to flexibility.

    www.mangojacks.com

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width