Overriding purge deleted messages-confirmation dialog

  • Thread starter Thread starter Lars Moastuen
  • Start date Start date
L

Lars Moastuen

I have written a macro that traps the delete key, and automaticly purges
messages. Problem is that purge messages brings up and yes/no/cancel
dialog. I bypass this by using sendkeys, but this isn't a good solution
(the delay especially). Is there any (better) way to override the
dialog, or is there maybe some other way of purging deleted messages?

This is how I execute the purge:
Set purge = ActiveExplorer.CommandBars.FindControl(ID:=5583)
purge.execute

Lars Moastuen

*** Sent via Devdex http://www.devdex.com ***
Don't just participate in USENET...get rewarded for it!
 
If you want to permanently delete messages while bypassing any dialogs or
putting the messages into the Deleted Items folder, which using the Outlook
object model to delete items will do, you can use CDO 1.21 (optional
installation for Outlook 2000 and later) or Extended MAPI (C++ or Delphi
only) or Redemption (3rd party library located at
www.dimastr.com/redemption).

Those API's have Delete methods that completely delete an item without
dialogs or sending the item to Deleted Items.
 
Back
Top