Link to home
Start Free TrialLog in
Avatar of BITASCII
BITASCIIFlag for United States of America

asked on

Outlook Programing - Inbox Cleanup on Quit Event

Does anyone know of VB code that can automagically move Inbox items older than 14 days into a user-defined folder, for example Inbox2, on Outlook client 2003's Application_Quit() event?  We have Inbox retention policies on our Exch 2003 Servers, but they don't fit our needs and Admins really don't have time to customize - hence our need for local VB code.  Thanks!  
ASKER CERTIFIED SOLUTION
Avatar of Chris Bottomley
Chris Bottomley
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
To Create a macro:
------------------

Alt + F11 to open the macro editor
  For workbook event handlers:
     In the project tree select as appropriate:
      OUTLOOK      : thisOutlookSession
     In the workpane select as appropriate:
      OUTLOOK      : General
     In the workpane select the required 'event', (i.e. 'open').
     Insert the required macro(s) into the selected subroutine.
  For User Code:
     Insert | Module to insert a code module into the project
     In the project tree select the module.
     Insert the required macro(s) into the selected module, ('Module1' or similar)
Close the Visual Basic Editor.

Check Security as appropriate:
------------------------------

In the application select Tools | Macro | Security
Select Medium
Select OK

Chris
Glad to have helped ... andthanks for the grade.

Chris