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

how to forward 6000 mails with VBA in OUTLOOK??



 
 
Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #2  
Old April 6th 06, 06:03 PM posted to microsoft.public.outlook.program_vba
Eric Legault [MVP - Outlook]
external usenet poster
 
Posts: 830
Default how to forward 6000 mails with VBA in OUTLOOK??

Here's a macro that's folder independant. Just select the messages that you
want to forward and run it:

Sub ForwardSelectedMessages()
On Error Resume Next

Dim objItem As Object
Dim objForward As Outlook.MailItem

For Each objItem In ActiveExplorer.Selection
If objItem.Class = olmail Then
Set objForward = objItem.Forward
objForward.To = "
objForward.Send
Set objItem = Nothing
Set objForward = Nothing
End If
Next

Set objItem = Nothing
Set objForward = Nothing
End Sub

--
Eric Legault (Outlook MVP, MCDBA, old school WOSA MCSD, B.A.)
Try Picture Attachments Wizard for Outlook:
http://www.collaborativeinnovations.ca
Blog: http://blogs.officezealot.com/legault/


"Dong Gaofeng" wrote:

dear all,

inbox
|--mailbox_A
|--mailbox_B
|--mailbox_C

how can I use VBA to forward all mails in mailbox_C to another email??

thank you~



 




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
Hotmail forward to Outlook XP? ~~Nightcrawler~~ Outlook - General Queries 2 March 30th 06 05:10 AM
Using VBA for Outlook and VBA for Access within Access Sardonic Outlook and VBA 1 March 17th 06 12:34 PM
I just deleted the some 6000 posts......... Yolanda Martin Outlook Express 6 February 3rd 06 12:02 AM
Forward all e-mails from Outlook Maxim Kazitov Add-ins for Outlook 1 January 15th 06 10:43 PM
Forward e-mail from Outlook Maxim Kazitov Outlook - General Queries 3 January 13th 06 01:37 PM


All times are GMT +1. The time now is 07:05 PM.


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.