Save attachments from multiple selected items in Outlook (VBA)

This VBA sample illustrates how to save attachments from multiple selected items in Outlook.

 
 
 
 
 
4.8 Star
(84)
85,914 times
Add to favorites
Office
9/7/2016
E-mail Twitter del.icio.us Digg Facebook
Sign in to ask a question


  • Error Message
    1 Posts | Last post Thu 5:05 PM
    • I keep getting a message that "No attachment(s) in the selected Outlook Items"
      Any idea what might be happening.
  • Need the updated one for Outlook 2016
    2 Posts | Last post August 04, 2017
    • Need the updated one for Outlook 2016
    • Yes, I need an updated version for Outlook 2016 as well.
  • Overwrite old attachments
    1 Posts | Last post March 07, 2017
    • Thanks for the sample! 
      
      I would like to overwrite attachments with the same name based on the date that i received the mail (latest attachment should be saved). Is this possible?
      
      Also I would only like to save Excel files.
      
      I would really appreciate your help 
  • Saving only .Doc & PDF (no embedded pictures, jpegs etc)
    1 Posts | Last post December 07, 2016
    • HI, 
      
      THank you. This works like a charm!
      
      I only want to save documents like PDF, .Doc, .Docx. I do not want embedded pictures, jpegs etc
      
      Is there a way of doing this?
      
      Many thanks
      
      Stuart
  • Saving attachments from each email in a different subfolder
    1 Posts | Last post October 21, 2016
    • Is it possible to modify the macro so it creates a subfolder for each email and downloads each specific email's attachments to that subfolder? We have 300 emails and thousands of attachments to download and organize, this would be really helpful.
      
      Thank you for this tool, works great!
  • Limit of 200 saved attachments
    2 Posts | Last post September 26, 2016
    • Hi,
      
      Thanks for a great work saver! Works great, albeit with one small caveat:
      
      When selecting more than 200 items, the macro (at least in my environment) saves only 200 attachments. The message at the end of the macro shows a correct number (ie "377 attachments saved", nonetheless the real number of files in the target directory is 199.
      
      I am wondering if that's something related to the topic discussed here: http://www.pcreview.co.uk/threads/runtime-error-when-using-saveasfile-method-to-save-outlook-attachm.3495945/
      
      Perhaps my environments puts some kind of limitation on the number of files saved?
      
      Thanks!
    • Hello,
      Have you gotten this limit resolved? I am finally cleaning my emails and I have about 2000 emails that I would like to download the attachments. This bas is still awesome if I want to break 200 at a time; but it would be nice to get an idea about the 199 limit.
      
      Regards,
  • Change Date
    2 Posts | Last post September 26, 2016
    • Can you please help me to modify the date of the created file when already exist by the Received Date of the email? instead of Format(Now, "_mmddhhmmss") part I would like to add the Received Date and Time.
    • Hello,
      Have you gotten this limit resolved? I am finally cleaning my emails and I have about 2000 emails that I would like to download the attachments. This bas is still awesome if I want to break 200 at a time; but it would be nice to get an idea about the 199 limit.
      
      Regards,
      
  • Running the macro in the Advanced Find Dialog Box
    1 Posts | Last post July 20, 2016
    • Hi,
      
      does anyone knows how to run the macro after have executed an Advanced Search?
      
      Thanks.
  • Edits to default the path?
    1 Posts | Last post June 09, 2016
    • Anyone suggest the needed edit to simply default the path as opposed to using the dialogue box and selecting the path?
      
      I was playing with strFolderPath, CGPath.I also know I need to remove the dialogue call code.
      
      Rob 
  • remove the file & have a link path to saved file
    1 Posts | Last post December 21, 2015
    • I wish macro;
      * to put a line as a path link to saved destination into email body
      * to remove the file and put a line in the email body for removed file names
      Thanks
1 - 10 of 32 Items