Outlook 2010 How to Copy Outlook Attachment to a Specific Folder?

geofferyh

Member
Outlook version
Outlook 2010 32 bit
Email Account
POP3
The attached VBA macro works with Outlook 2010 Rules, saving the attachment in messages that meet the condition of the rule. The attachment is supposed to go into "My Documents". Since there is no "My Documents" folder in Windows 10, the attachment is being saved to the "Attachments" folder on my "D:" drive (my "Documents" folder has been moved to the "D:" drive).

Instead of saving attachments to the "My Documents" or "Documents" folder, I would like the macro to save to a different folder with a very specific location, that being: C:/MarinaPro/ResScheduler.

VBA is totally new to me and I can't figure how to get it done.
 

Attachments

geofferyh

Member
Outlook version
Outlook 2010 32 bit
Email Account
POP3
Change this:
strfolderpath = CreateObject("WScript.Shell").SpecialFolders(16)
strfolderpath = strfolderpath & "\Attachments\"

to
strfolderpath = "c:\new folder\Attachments\"
Thanks Diane, this works well and is the solution I came up with just before I got your post.
 

9MilesLong

New Member
Outlook version
Outlook 2016 64 bit
Email Account
Office 365 Exchange
Hello,

I'm new to this forum and came across this post. It look similar to what I need to accomplish but I still need some assistance on how to do it since I don't have much knowledge in this field.

Basically I inherited this from somebody that is no longer with my company. There used to be a job that sends out an email with an attachment. That attachment will then be copied to a network folder - \\NetworkFolder\NetworkFolderSubFolder\Imports\Import\
After the attachment gets copied. The email will be deleted.

My challenge is how can I get this to work? It used to work for a couple of years and for some reason it didn't. Also this email is sent to a shared email address and if I need to create a rule for this, it also need to be running on its own without intervention.

Thank you in advance.
~Louie
 
Top