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 biv343 on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

how to change code for macro saving attachments?

Status
Not open for further replies.

Gerrit Broekhuis

Programmer
Aug 16, 2004
316
NL
Hi,

I found some nice code to copy Outlook Attachments for all messages.

This code contains the lines:

For Each objMsg In oInbox.Items
If objMsg.Class = olMail Then
'other instructions here
End If
Next

However, I want the instructions to act only on the selected email message and not on all of them. How should I change the code to do that?

Regards, Gerrit
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top