A Microsoft Outlook email forum. Outlook Banter

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » Outlook Banter forum » Microsoft Outlook Email Newsgroups » Outlook and VBA
Site Map Home Register Authors List Search Today's Posts Mark Forums Read Web Partners

Emptying Deleted Items



 
 
Thread Tools Search this Thread Display Modes
  #1  
Old August 24th 06, 01:56 PM posted to microsoft.public.outlook.program_vba
Darren Hermes
external usenet poster
 
Posts: 1
Default Emptying Deleted Items

Hello everyone.

Firstly, thank you to Sue Mosher for her assistance on a recent question I
posted and her solution did the trick.

I now have another question!

Is it possible to use some code to empty the deleted items folder as part of
a macro?

Many thanks.
  #2  
Old August 25th 06, 07:15 AM posted to microsoft.public.outlook.program_vba
Michael Bauer [MVP - Outlook]
external usenet poster
 
Posts: 1,885
Default Emptying Deleted Items

Am Thu, 24 Aug 2006 04:56:02 -0700 schrieb Darren Hermes:

Dim Items as Outlook.Items
Dim i as Long
Set Items=Application.Session.GetDefaultFolder(olFolde rDeletedItems).Items
For i=Items.Count To 1 Step-1
Items(i).Delete
Next

--
Viele Gruesse / Best regards
Michael Bauer - MVP Outlook
-- www.VBOffice.net --


Hello everyone.

Firstly, thank you to Sue Mosher for her assistance on a recent question I
posted and her solution did the trick.

I now have another question!

Is it possible to use some code to empty the deleted items folder as part

of
a macro?

Many thanks.

  #3  
Old August 26th 06, 03:52 AM posted to microsoft.public.outlook.program_vba
Michael Bednarek
external usenet poster
 
Posts: 28
Default Emptying Deleted Items

On Fri, 25 Aug 2006 07:15:31 +0200, "Michael Bauer [MVP - Outlook]"
wrote in microsoft.public.outlook.program_vba:

Am Thu, 24 Aug 2006 04:56:02 -0700 schrieb Darren Hermes:

Dim Items as Outlook.Items
Dim i as Long
Set Items=Application.Session.GetDefaultFolder(olFolde rDeletedItems).Items
For i=Items.Count To 1 Step-1
Items(i).Delete
Next


While we're on this subject - I've been looking for a long time for a
way to purge items from a folder's dumpster with VBA.

Has anyone found a way, except by SendKeys, of doing that?

Firstly, thank you to Sue Mosher for her assistance on a recent question I
posted and her solution did the trick.

I now have another question!

Is it possible to use some code to empty the deleted items folder as part of
a macro?


--
Michael Bednarek http://mbednarek.com/ "POST NO BILLS"
 




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Remove from server when deleted from 'Deleted Items' - Archiving? [email protected] Outlook - General Queries 1 August 2nd 06 07:34 PM
Reading mails from Sent items, Deleted items, Draft folder of outlook from VB6.0 Viswanathan Outlook - General Queries 8 May 26th 06 05:31 PM
emptying the deleted items folder billp Outlook and VBA 1 March 20th 06 09:25 PM
Deleted items not emptying David H Outlook Express 4 February 11th 06 12:26 PM
Recover deleted messages after emptying deleted items folder Gail Outlook Express 2 January 30th 06 06:18 PM


All times are GMT +1. The time now is 07:04 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.Search Engine Friendly URLs by vBSEO 2.4.0
Copyright ©2004-2025 Outlook Banter.
The comments are property of their posters.