+ Reply to Thread
Results 1 to 6 of 6

Macro to email files from folder automatically

  1. #1
    Forum Contributor
    Join Date
    11-26-2010
    Location
    usa
    MS-Off Ver
    Prefer Excel 2003 but 2007 is great!
    Posts
    952

    Macro to email files from folder automatically

    Hi all

    I am wondering if its possible to have a macro setup that will go into a specified folder and then email the file (pdf) to the respective individuals? I have the following task
    1) Outlook macro goes into the following folder:
    C:\Users\TORHXH\Desktop\Timekeeper performance overview\PDF

    2) The folder has PDF files with the following naming convention:
    Ellis, Mark - May.pdf
    --> I would like the macro to email e.g. the above named file to "mark.ellis@xyz.com" (the file shows last name, first name)

    3) In the body of the email have the following
    Subject line
    [Employee name i.e. Mark Ellis] TK Performance overview [Month, year e.g. May, 2017] (month of taken from file name?)

    Body of email:
    Hello [Employee name e.g. Mark Ellis]

    Attached is you performance dashboard that shows you Key Performance Indicators (KPIs) as at FY [month, year], which shows the following KPIs
    1. ABC
    2. ABC
    3. ABC
    4. ABC

    The purpose of this dashboard is to keep you apprised of your own progress so that you can plan accordingly for the remainder of the year.

    If you have any questions or feedback related to your report of the KPIs, please do not hesitate to reach out to me.

    4) Send out the email.

    There will be a total of +/-110 PDF files, so I would like if this process can be automated as we will be sending these files each month?

    Pls let me know...thank you in advance!

  2. #2
    Forum Expert Arkadi's Avatar
    Join Date
    02-13-2014
    Location
    Smiths Falls, Ontario, Canada
    MS-Off Ver
    Excel 2010
    Posts
    2,792

    Re: Macro to email files from folder automatically

    Hi again

    I assume this is part of the file we worked on earlier for creating pdfs? It might make sense to add a column next to the employee names in Excel, and just have excel email them as it creates them (invoking outlook in the process)
    Or the code could build the email name based on your post criteria, a list is handy but not necessary.
    Let me know if that idea works for you, and I can work on some code.
    Last edited by Arkadi; 05-18-2017 at 04:17 PM.
    Please help by:

    Marking threads as closed once your issue is resolved. How? The Thread Tools at the top
    Any reputation (*) points appreciated. Not just by me, but by all those helping, so if you found someone's input useful, please take a second to click the * at the bottom left to let them know

    There are 10 kinds of people in this world... those who understand binary, and those who don't.

  3. #3
    Forum Contributor
    Join Date
    11-26-2010
    Location
    usa
    MS-Off Ver
    Prefer Excel 2003 but 2007 is great!
    Posts
    952

    Re: Macro to email files from folder automatically

    Quote Originally Posted by Arkadi View Post
    Hi again

    I assume this is part of the file we worked on earlier for creating pdfs? It might make sense to add a column next to the employee names in Excel, and just have excel email them as it creates them (invoking outlook in the process)
    Or the code could build the email name based on your post criteria, a list is handy but not necessary.
    Let me know if that idea works for you, and I can work on some code.
    Hi Arkadi

    Yes, it is infact part of the earlier help with the PDFs.

    I am open to suggestions, so if it easier or less redundant to have Excel email the copies that works for me as well? I can add a column to the employee name that contains their email address - i assume that is what you meant?

    Pls see attached file - it has the emails next to it. WOuld it be possible to have the subject and body of email contain the info., I have listed in my post earlier?

    kindly let me know. thanks a million for your awesome support

    FYI: the email address is to a fake url in the file
    Attached Files Attached Files

  4. #4
    Forum Expert Arkadi's Avatar
    Join Date
    02-13-2014
    Location
    Smiths Falls, Ontario, Canada
    MS-Off Ver
    Excel 2010
    Posts
    2,792

    Re: Macro to email files from folder automatically

    I made some small changes to the first macro I had made, so you will need to replace the code in that module with the code below:

    Please Login or Register  to view this content.

  5. #5
    Forum Expert Arkadi's Avatar
    Join Date
    02-13-2014
    Location
    Smiths Falls, Ontario, Canada
    MS-Off Ver
    Excel 2010
    Posts
    2,792

    Re: Macro to email files from folder automatically

    Did this resolve the question? If so please mark the thread as solved? Thanks in advance

  6. #6
    Forum Contributor
    Join Date
    11-26-2010
    Location
    usa
    MS-Off Ver
    Prefer Excel 2003 but 2007 is great!
    Posts
    952

    Re: Macro to email files from folder automatically

    Quote Originally Posted by Arkadi View Post
    Did this resolve the question? If so please mark the thread as solved? Thanks in advance
    Yes, thank you ....I tried to do it the other day but gives me an error message and continues today - which is strange.

    I will try to do it again shortly

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1