1. Here's a thread that needs an answer: BCM remote database connection issue

Save all incomming and sent mails to folder on PC as .msg files

Discussion in 'Using Outlook' started by wargro, Jan 30, 2012.

  1. wargro


    Hi there

    I am looking for a way to save all incomming emails as well as emails I send to automatically be saved into a incomming and sent folder on my harddrive.

    I know file names can be an issue if file name already exists, so I'm assuming it would be best to date and time stamp the file name.

    I found this link http://www.vbaexpress.com/kb/getarticle.php?kb_id=875 , but it seems to be once off. I want a macro that will run every time a mail is sent or received.

    Thanks in advance


  2. Diane Poremsky

    Diane Poremsky

    Senior Member
  3. wargro



    Thanks for that. I don't seem to be able to get it to work though?

    Should I just create a new module and save it there?

    What do I all need to change in the script? Just the File Path?

    Thanks so much for your help so far...

  4. Diane Poremsky

    Diane Poremsky

    Senior Member
    Put it in a module or in the thisoutlooksession and change the path.

    Is any of the code red? That means there is an error in the code.

    How many accounts are in outlook? I'm not sure if it doesn't work in outlook 2010 or doesn't work with multiple accounts. I'll check with the author.

  5. wargro


    Thanks for the response.

    Sorry, I should have said that this is for a different pc thats running 2007 Outlook.

    It seems I got the kind to run, but there is an error that comes up when I receive an email.

    Run-time error '-2147287035 (80030005)':

    You don't have appropriate permission to perform this operation.

    -And when I debug this section of the code is highlighted:

    oMail.SaveAs sPath & sName, eType

    I'm not an administrator on the person I'm trying to do this on. Is that the cause of this?

    If so, how can I work around it?


  6. wargro


    I got it working!! Was a permissions issue on my PC.

    Thanks for all the help, a question however... anyone want to venture into editing the code to work for sent items as well?

  7. PatP


    I use the "Save Sent Emails To" and "Direct Replies To" features under the Options tab and it works great. I just have to remember to set them for every mass email. Unfortunately, the "From" feature under the Options tab is grayed out when using mass email - I would like to set the From address to one of our Enterprise email accounts instead of my personal account.

Similar Threads
Forum Title Date
Outlook VBA and Custom Forms How do I 'Save Copy of Sent Item to Folder' for a Shared Mailbox Monday at 10:47 PM
Using Outlook Item cannot be saved because it was modified by another user or window Sunday at 9:45 AM
Using Outlook.com accounts in Outlook Message Save add ins do not work with EAS Sep 16, 2014
Outlook VBA and Custom Forms .SaveAsFile Sep 8, 2014
Outlook VBA and Custom Forms VBA code to save email attachments (PDF) as email subject line Aug 29, 2014

Share This Page