+ Reply to Thread
Results 1 to 12 of 12

mail automation support

  1. #1
    Registered User
    Join Date
    06-03-2019
    Location
    madurai
    MS-Off Ver
    2019
    Posts
    64

    Unhappy mail automation support

    Dear team,

    if I want to send daily updates as attached below

    sheet 2 has the list of mail ids, which need to be in to address automatically.

    the basis that i can update the summary details and the current sheet should go as an attachment with subject name,

    To address should change automatically till the given list and then stop.

    pls, support me with Marco to execute the required output automation.

    TO, CC, subject & Mail Boday need to pick along with that...(so i can hide this and send only summary)
    Attached Files Attached Files

  2. #2
    Forum Expert dflak's Avatar
    Join Date
    11-24-2015
    Location
    North Carolina
    MS-Off Ver
    365
    Posts
    7,926

    Re: mail automation support

    Fortunately I have a "plug and play" macro for mailing using outlook. Here are the arguments that can be passed to it:
    ' ToString = List of addressees in To field, semicolon delimited
    ' SubjectString = Subject of the mail Message
    ' BodyString = Body of the mail message
    ' ReplyTo = (Optional) Reply to email address
    ' OnBehalfOf = (Optional) Mail on behalf of (must have permissions)
    ' CCString = (Optional) List of addressees in CC field, semicolon delimeted
    ' BCCString = (Optional) List of addresses in BCC filed, semicolon delimited
    ' AttachmentName = (Optional) List of full-path name attachments, semicolon delimited
    ' SendDisplay = (Optional) True = Send mail automatically, False = display only as draft

    I changed the mail Id range to a table. There are too many good reasons NOT to use Excel Tables.

    The Control Panel is used for scratch calculations and to set the Mail Flag (SendDisplay). I set it to False for the purposes of testing. With false, the mail is displayed and not sent automatically. You will need to press send to send t he mail. When set to true, mail is sent automatically without human intervention.
    Attached Files Attached Files
    One spreadsheet to rule them all. One spreadsheet to find them. One spreadsheet to bring them all and at corporate, bind them.

    A picture is worth a thousand words, but a sample spreadsheet is more likely to be worked on.

  3. #3
    Registered User
    Join Date
    06-03-2019
    Location
    madurai
    MS-Off Ver
    2019
    Posts
    64

    Re: mail automation support

    Thank you. working fine. One small concern, the mail attached sheets are with formula reference. is there any way to do a paste special on the attachment?

  4. #4
    Forum Expert dflak's Avatar
    Join Date
    11-24-2015
    Location
    North Carolina
    MS-Off Ver
    365
    Posts
    7,926

    Re: mail automation support

    Here is the version that corrects that issue.
    Attached Files Attached Files

  5. #5
    Registered User
    Join Date
    06-03-2019
    Location
    madurai
    MS-Off Ver
    2019
    Posts
    64

    Re: mail automation support

    thank you so much..!

  6. #6
    Registered User
    Join Date
    06-03-2019
    Location
    madurai
    MS-Off Ver
    2019
    Posts
    64

    Re: mail automation support

    Hi dflak, i require one support, the sheet sending static mails, if i want to make it dynamic, basis the mail id, I need to populate the data and send the sheet.
    trying but not working. Can you help me with this pls?
    Attached Files Attached Files

  7. #7
    Forum Expert dflak's Avatar
    Join Date
    11-24-2015
    Location
    North Carolina
    MS-Off Ver
    365
    Posts
    7,926

    Re: mail automation support

    Before I go further, do you want the information on rows 11-12 as an attachment or in the body of the text?

  8. #8
    Registered User
    Join Date
    06-03-2019
    Location
    madurai
    MS-Off Ver
    2019
    Posts
    64

    Re: mail automation support

    As an attachment, with past special

  9. #9
    Forum Expert dflak's Avatar
    Join Date
    11-24-2015
    Location
    North Carolina
    MS-Off Ver
    365
    Posts
    7,926

    Re: mail automation support

    This should do it. I made the assumption that you wanted the summary sheet as an attachment.

    I made some changes. Mail ID Base is a table, therefore, there is no need to add blank lines. As you add lines to it, the table will grow to accommodate the new lines.

    The code looks down the first column of this table, S.no. and it sets the value it finds on the control panel in cell B11. This value is used in the VLOOKUP against the table. For example, to find Mail To: =IFERROR(VLOOKUP(Working_ID,Table_Addresses,2,FALSE),"").

    This version of the spreadsheet has some new "innards." I needed to add some code to show both the body of the email text and also be able to include an HTML representation of a range.

    If you want to show just the two lines in the body of the email instead of as an attachment, I can do that rather easily now.
    Attached Files Attached Files

  10. #10
    Registered User
    Join Date
    06-03-2019
    Location
    madurai
    MS-Off Ver
    2019
    Posts
    64

    Re: mail automation support

    Super it's working. You are super cool thanks. one concern is when I change the Mail flag to True.
    mails are not going automatically, for each mail I need to click send, earlier it goes automatically why it get changed?
    can it get automated.
    Last edited by jimsenthil; 07-01-2022 at 10:25 AM.

  11. #11
    Forum Expert dflak's Avatar
    Join Date
    11-24-2015
    Location
    North Carolina
    MS-Off Ver
    365
    Posts
    7,926

    Re: mail automation support

    My bad. I forgot to include the flag while calling the mail program. This version should do it.
    Attached Files Attached Files

  12. #12
    Registered User
    Join Date
    06-03-2019
    Location
    madurai
    MS-Off Ver
    2019
    Posts
    64

    Re: mail automation support

    Thank you ...Dflak..working

+ 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. Run-time error '430' Class does not support automation
    By tfagan1978 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 04-13-2021, 05:16 PM
  2. Class does not support Automation or does not support expected interface
    By ccs_1981 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 01-28-2015, 05:57 AM
  3. Class does not support automation
    By mikeTRON in forum Excel Programming / VBA / Macros
    Replies: 12
    Last Post: 08-07-2013, 10:12 AM
  4. runtime 430 error- Class does not support Automation or does not support...
    By kimcole5 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 06-22-2012, 01:27 PM
  5. Class does not support Automation
    By donyc in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 02-17-2011, 10:29 PM
  6. Class does not support automation (err 430) - on copyfromrecordset
    By tjharlan in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 07-20-2007, 03:31 PM
  7. [SOLVED] Error 430: Class does not support automation...
    By pagates in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 08-22-2005, 03:05 PM

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