Answer the question
In order to leave comments, you need to log in
How do I set Outlook 2016 to automatically save incoming message attachments to disk?
How do I set Outlook 2016 to automatically save incoming message attachments to disk? Googled "Attachments Processor for Outlook" - but it's a paid solution. Is there an alternative? You want to automatically download an attachment as soon as an incoming message contains an attachment.
Answer the question
In order to leave comments, you need to log in
You need a macro and a corresponding rule. Add a new module to the project and put the code there
Public Sub saveAtt (itm As Outlook.MailItem)
Dim objAtt As Outlook.Attachment 'переменная для работы с вложениями
Dim saveFolder As String 'переменная для пути к папке сохранения
Dim sDateMail as string 'переманная для даты письма
'сохраняем в правильном формате время создания сообщения
sDateMail = Format(itm.CreationTime, "hh-mm-ss_dd.mm.yyyy")
'задаем путь к папке сохранения
saveFolder = "C:\Users\Username\Desktop\"
'перебираем все вложения в письме
For each objAtt in itm.Attachments
'сохраняем вложение в папку под именем: дата письма + название файла вложения
objAtt.SaveAsFile saveFolder & "\" & sDateMail & "_" & objAtt.FileName
'очищаем переменную с вложением
Set objAtt = Nothing
Next objAtt
End Sub
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question