Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Outlook macros 1

Status
Not open for further replies.

guava65

Programmer
Jul 20, 2001
238
US
I would like to create a macro that goes from the first message to the last message in a folder replying to each of them with static text.

I am VERY new at VBA. does anyone have a similar setup that I can use as an example?


I would like to:

1. open a message
2. reply to that message
3. replace the subject text with my subject
4. insert text to the message body
5. send the message
6. move to the next message and repeat the process.

Any help would be appreciated. Mahalo,
cg
 
Theoretically, you would do something like:

Set oNS = Application.GetNamespace("MAPI")
Set oFolder = oNS.GetDefaultFolder(olFolderInbox)
For Each oItem In oFolder.Items
oItem.Reply
oItem.Body = "new body"
oItem.Subject = "new subject"
oItem.Send
Next oItem Jon Hawkins
 
You may want to look into the Rules Wizard in Outlook. This may be handle what you want accomplished without the need to generate your own macros. Neil Konitzer, President
Freisoft
 
Thanks!

I decided to use the rules option. This does the job well without having to get too deep into the marcos. I'll still be looking into using marcos in the future.

The only thing I can't figure out is how to specify a diffent ID for the FROM field and also a different location for the REPLY TO field. Any ideas?

Thanks again for the help.

cg Mahalo,
cg
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top