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

Reverse loop?



 
 
Thread Tools Search this Thread Display Modes
  #1  
Old February 1st 06, 08:46 AM posted to microsoft.public.outlook.program_vba
yonina
external usenet poster
 
Posts: 4
Default Reverse loop?


Hi,

I have the following loop:

For Each mail In Folder.Items
..
..
..

Next

The loop runs from the first email that was sent/accepted to the last one.
How can I make the loop go backwords? from the last email that was
sent/accepted to the first?


Ads
  #2  
Old February 1st 06, 12:46 PM posted to microsoft.public.outlook.program_vba
Michael Bauer
external usenet poster
 
Posts: 435
Default Reverse loop?

Am Wed, 1 Feb 2006 00:46:29 -0800 schrieb yonina:

dim i&
For i=Folder.Items.Count to 1 step-1
set mail=Folder.Items(i)
Next

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


Hi,

I have the following loop:

For Each mail In Folder.Items
.
.
.

Next

The loop runs from the first email that was sent/accepted to the last one.
How can I make the loop go backwords? from the last email that was
sent/accepted to the first?

  #3  
Old February 2nd 06, 09:10 AM posted to microsoft.public.outlook.program_vba
yonina
external usenet poster
 
Posts: 4
Default Reverse loop?

Thank you!!!!!!!!!!!!!!!!!

That was exactly what I needed!!!!!!!!!!!!!!!!!!!

))

"Michael Bauer" wrote:

Am Wed, 1 Feb 2006 00:46:29 -0800 schrieb yonina:

dim i&
For i=Folder.Items.Count to 1 step-1
set mail=Folder.Items(i)
Next

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


Hi,

I have the following loop:

For Each mail In Folder.Items
.
.
.

Next

The loop runs from the first email that was sent/accepted to the last one.
How can I make the loop go backwords? from the last email that was
sent/accepted to the first?


 




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
I need to reverse aol security center changes to outlook 2003 okmerlin Outlook - Installation 1 February 7th 06 04:40 PM
How do I reverse order addresses are displayed in the TO block? CAPTN_242 Outlook - General Queries 2 February 6th 06 03:03 PM
Loop through a folder and forward each email to a given address needsomeoutlookhelp Outlook and VBA 1 February 1st 06 08:03 AM
How to loop through Outlook tasks in VBA Rick Williams Outlook and VBA 2 January 25th 06 07:59 PM


All times are GMT +1. The time now is 03:15 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.