+ Reply to Thread
Results 1 to 1 of 1

Trying to send an email with attachment using VBA

  1. #1
    Registered User
    Join Date
    02-26-2015
    Location
    Weymouth, Dorset
    MS-Off Ver
    2007
    Posts
    14

    Trying to send an email with attachment using VBA

    Sorry - just realised I posted this in the wrong forum - I will close this and move to the right one!

    Hi

    I'm not sure whether what I am trying to do is possible, but I'd be grateful for any replies, even if just "you can't do that"! Every month, I need to send out reports to all my heads, which involves exporting some data from Oracle Discoverer to a main document, then using VBA to create a number of separate workbooks, all of which is working fine. However, I then need to email each of the workbooks I've just created to a different person. There are well over 200 of them, so automation is definitely the way to go. My goal is to open each workbook separately from within the main document, add the opened workbook as an attachment to an email and then send that email to the correct recipient. I have got as far as creating the email and adding the attachment just by using the following...

    Workbooks.Open Filename:= _
    "[full file path and name] School Health.xlsx"
    Application.Dialogs(xlDialogSendMail).Show

    ...but I can't work out how to use VBA to add the details of the recipient (there will be at least one person in the "To" box and one "CC" and then to automatically send the email. Is this even possible? Many thanks for any help anyone can provide.

    Apologies if this has been asked before - I did a quick search but couldn't see anything that exactly matches what I am looking for.
    Last edited by ed67; 06-22-2018 at 05:48 AM. Reason: Posted in wrong forum

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Email from Excel just won't send the attachment
    By CorinneGermany in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 04-16-2015, 11:03 AM
  2. Macro to send email with attachment for each unique email Ids
    By vijanand1279 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 07-06-2014, 07:12 AM
  3. [SOLVED] Savecopyas then send as email attachment
    By trisoldee in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 04-15-2014, 11:52 AM
  4. [SOLVED] send email with attachment
    By ks1102 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 12-06-2013, 02:29 AM
  5. How to send email with attachment
    By staciam in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 02-04-2011, 12:19 PM
  6. How to send the doc to email as an attachment
    By mdkaye in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 05-08-2009, 06:25 AM
  7. [SOLVED] cant send email attachment from excel
    By DKT in forum Excel - New Users/Basics
    Replies: 8
    Last Post: 11-21-2005, 09:30 PM

Tags for this Thread

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