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!

MICROSOFT OUTLOOK: Saving olOLE's

Status
Not open for further replies.

sclary34

MIS
Jan 28, 2002
8
US
Does anyone know how to save olOLE's attachments out to a directory?
 
i save the all message contain like this as html
 
What I'm trying to do is programatically remove attachments from Outlook messages. When someone copies and pastes part of a spreadsheet for example, Outlook treats that as an attachment and its called an olOLE. I haven't found any methods that will save these attachments out to a directory.
 
where oMail represents the mail item in question:

For Each oAttach In oMail.Attachments
If oAttach.Type = olOLE Then 'olOLE = 6
oAttach.SaveAs "C:\temp\" & oAttach.FileName
End If
Next Jon Hawkins
 
Jon,

When I run that code it gives me the Run-Time error 'Outlook cannot do this action on this type of attachment.'

Thanks,

Scott
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top