Download : Excel Macro Application to Send Multiple Emails – 2.0

.

Hello Friends,

I got many good response on the tool – Send Multiple Email Workbook. I also got a request to implement much other functionality as well. The attachment was one of them. In this version, I have added the attachment functionality with some other small fixes. Download the latest file from the end of this article and let me know your feedback.

Send Multiple Email - New

Send Multiple Email - New

New Features:

1. Attachment: You can add up to 5 attachments to each email. There are two ways of attaching a document to the mail:

  • i) You can directly type the path of the file which you want to attach in the Corresponding cell as shown in the picture
  • ii) Select the cell where you want the file path and click on the Browse button. Select your file and click Ok. You are done. The complete URL of that file will be pasted in that cell.

Old Features:

1. Using this Tool you can send an unlimited number of individual emails: What is Individual Mail? If you want to send an email to 1000 different email IDs, ONE by ONE, means you are not keeping all the 1000 IDs in the TO list, and sending one single mail, is called individual mail. In such a case it becomes very difficult to send the same email 1000 times. This tool will help you do this just by a single Click.

2. You can input CC and BCC IDs as well: Wherever you want any email ID in CC or BCC, you have the freedom to put it.

3. All the emails sent SUCCESSFULLY will remain in white background color: The emails sent successfully will remain in WHITE BACKGROUND.

4. All the emails which are FAILED, will be marked in RED Background Color: The emails which could not be sent successfully will be marked as RED BACKGROUND

5. A number of Successful and Failed Email Sent will be displayed at the end: On top of the Tool, below the Selection Area, at the end of the Mail Sending Process, the Total Number of Successful and Failed records will be displayed.

6. Error Description: In Excel Sheet there is a Column for the Error Description. For all the Emails which are failed, an Error Description will be put there. For Successful mails, it is set to blank.

Download Now

Buy a coffee for the author

Adsense

Download FREE Tools and Templates

There are many cool and useful excel tools and templates available to download for free. For most of the tools, you get the entire VBA code base too which you can look into it, play around it, and customize according to your need.

Dynamic Arrays and Spill Functions in Excel: A Beginner’s Guide
Dynamic Arrays and Spill Functions in Excel: A Beginner’s Guide

In today's tutorial, we'll be diving into the exciting world of dynamic arrays and spill functions in Office 365 Excel. These features have revolutionized the way we work with data, providing a more flexible and efficient way to handle arrays. I am going to explain...

How to Declare a Public Variable in VBA
How to Declare a Public Variable in VBA

While programming in VBA sometimes you need to declare a Public Variable that can store the value throughout the program. Use of Public Variable: Let's say you have 4 different Functions in your VBA Code or Module and you have a variable that may or may not be...

How to Copy content from Word using VBA

As many of us want to deal with Microsoft Word Document from Excel Macro/VBA. I am going to write few articles about Word from Excel Macro. This is the first article which opens a Word Document and read the whole content of that Word Document and put it in the Active...

What is Excel Formula?

Excel Formula is one of the best feature in Microsoft Excel, which makes Excel a very very rich application. There are so many useful built-in formulas available in Excel, which makes our work easier in Excel. For all the automated work, Excel Macro is not required. There are so many automated things can be done by using simple formulas in Excel. Formulas are simple text (With a Syntax) which is entered in to the Excel Worksheet Cells. So how computer will recognize whether it is a formula or simple text? Answer is simple.. every formula in Excel starts with Equal Sign (=).

You May Also Like…

54 Comments

  1. Rajveer

    Its amazing sharing friend..

    But can we have the access of VBA code?

    Can you please provide us password for VBA..?

    Thanks,

    Rajveer

    Reply
  2. Shivpal

    Hi Vish,

    This is an amazing tool!

    Is there a way to keep the formatting I have in the body cells of the excel file in the email as well? So if I have words bolded/underlined in the excel cell, they will stay bolded and underlined in the email?

    Thank you for this wonderful creation!

    Best,

    Shiv

    Reply
      • Dhanush

        Hi Vishwa,

        How to embed the picture, graph or table in the body of the email. If I have to embedd multiple graphs or tables in the body of the email, is that possible?

        Thanks
        Dhanush Anand

        Reply
        • Vishwamitra Mishra

          Hi Dhanush,

          Please refer this article. Yes it is possible to attach as many graphs as you want.

          Reply
          • Rajasekar K

            Dear Vishwa,
            I have tried to embed the picture, graph or table in the body of the email. But not able to do kindly help to me since I am not having much knowledge about macro.

  3. rahul

    please help me out to download this file

    i have downloaded it but its not getting opened

    i am using excel 2003.please help me to use this feature developed by you.

    thanks in advance

    Reply
  4. Dips

    How to CC multiple people?

    Reply
  5. Rudra Sharma

    Hi,

    It is really cool tool. Thanks for sharing it. I have few suggestions

    1.in to and cc section mulitple email ids should be accomodated as we may need to copy the email to many people.

    2.while attaching it should allow to select multiple attachments @ once.

    Reply
  6. Miguel Pinto

    Hi,

    This is an amazing tool!

    Is it possible to use .display to send manually insted .Send that Will send it straight away?

    I am not able to edit the macro…

    Thanks

    Reply
  7. Jeetesh

    Hi,

    First let me congratulate you for preparing such a awesome tool.

    My email body has the minimum lenth of 2000 character and i am not able to see that in excel.

    Request you to help on the above matter.

    Regards,

    Jeetesh

    Reply
  8. Himanshu

    Hi friend,

    Please provide the password for VBA, I need to use the code in one of my project tool.

    Thanks in advance!!

    Regards,

    Himanshu Gupta

    Reply
  9. Omveer Singh

    Respected Sir,

    Kindly share the password of vba code.

    Regards

    Omveer Singh

    Reply
  10. Gnanaprakash

    In Outlook, while sending multiple mails, i get a warning whether to Allow or Deny to send the mail…

    Reply
    • Vishwamitra Mishra

      Dear Gnanaprakash,

      That is because of the security settings in your Outlook. You can lower the security in your outlook and it will be fine if you want.

      Reply
      • Gnanaprakash

        Thanks for your reply… i got rid of the warning..

        is there any way to send mails using different from address i.e from my BA (Business Address)and not PA(Personal Address)?

        and i m sure your not gonna share the VB Password…
        but can you post the snippet used to send the mail function?

        thanks in advance…

        Reply
        • Vishwamitra Mishra

          Dear Gnanaprakash,
          Glad that you got rid of the security message in outlook.
          If your business mail is providing a connection method then ofcourse it is possible. But generally your business email will be configured on Outlook and in that case no matter which email ID is configured on outlook, this excel will send email through your business or personal IDs.

          There are many articles written with code snippets of sending email using Outlook, gmail yahoo etc. you can go through them.
          http://learnexcelmacro.com/wp/excel-macro-tutorial/

          Reply
  11. Akash

    Hi Vishwa,

    My name is Akash currently working in bangalore, first thanks for the above macor this is really very good. Just wanted to know to do you conduct Macro clases also ? because i am really interested to learn coding.

    Let me know
    Akash

    Reply
    • Vishwamitra Mishra

      Thanks Akash !!

      I have not started taking VBA classes but in future I am planning to do so as I am getting many request through my site.

      Reply
  12. nitin

    gv me password

    Reply
  13. nitin

    m using lotus notes in ofc n need to change coding bcz in dat liat lotus in not avilable

    Reply
  14. Suresh Chandan

    Good utility

    Reply
  15. long

    Private Sub cmbSelectEmail_DropButtonClick()

    If cmbSelectEmail.ListCount 8 Then
    cmbSelectEmail.Clear
    With cmbSelectEmail
    .AddItem “Outlook”
    .AddItem “Gmail”
    .AddItem “Yahoo”
    .AddItem “Hotmail”
    .AddItem “Rediffmail”
    .AddItem “AOL”
    .AddItem “Netscape”
    .AddItem “Others”
    End With
    End If
    End Sub

    Private Sub cmdSendEmail_Click()

    Application.DisplayAlerts = False

    If cmbSelectEmail.Value “Outlook” Then

    If Range(“B7”).Value = “” Then

    MsgBox “At least One Email Should be there to be sent”
    Exit Sub
    End If

    frmSendEmailOption.Show

    Else

    Call SendEmailUsingOutlook
    End If
    Application.DisplayAlerts = True
    End Sub

    Private Sub CommandButton1_Click()

    DoEvents

    lblProgressBar.Width = 1
    lblProgressBar.Caption = “0%”
    Sheet1.Label1.Caption = “#Emails Successfully Sent: 0 #Emails Failed: 0”

    cmbSelectEmail.Value = “Outlook”

    End Sub

    Private Sub CommandButton2_Click()
    On Error GoTo err
    Dim fd As FileDialog
    Set fd = Application.FileDialog(msoFileDialogFilePicker)
    With fd
    .ButtonName = “Select”
    .AllowMultiSelect = False
    .Title = “Choose Attachments”
    .InitialView = msoFileDialogViewDetails
    .Show
    End With
    Selection.Value = fd.SelectedItems(1)

    err:

    Reply
  16. Katheryn Mueller

    Hi Vishwa,

    Your blog is very helpful! I have a small and (easy for you..not me) macro project that I am working on. It is basically macro to send multiple emails + macro to send HTML from word doc.

    We would be willing to pay for your assistance. If interested, can you please contact me?

    Thank you,

    Katheryn

    Dallas, TX

    Reply
  17. Hitesh

    I m have installed windows live mail in my pc. so please confirm me how it will work without using outlook.

    Reply
  18. Mangal

    But can we have the access of VBA code?

    Can you please provide us password for VBA..?

    Thanks in Advance
    Mangal

    Reply
  19. Amol

    I want to send all the mails without any warning.. Please help on this.

    Reply
  20. Ankeet

    Hi,

    I have run the tool successfully on my company outlook however when I used the same file for my client network (client Outlook) it has given error on

    Call sendmail

    It stucks here… no idea what is happening as when I used the same file on my normal system it is working fine. Can you please help me

    Reply
    • Vishwamitra Mishra

      Dear Ankeet,

      Kindly share me the error you are getting while running the tool in your client’s machine. To get the error, I would recommend you to run the code in debug mode. If you do not know how to run VBA code in debug mode, kindly refer this article : http://learnexcelmacro.com/wp/2015/12/debug-vba-code/

      Reply
  21. Saroja kumar sahu

    Hi,

    Can you please share VBA password

    Reply
  22. rajasekar

    Dear Vishwa,
    If it is possible can u provide the password

    Reply
  23. Rukshi

    hi,

    this is really good, but if you can help us with the macro which can attached 1 or more file from the folder with the name of the file as an option for selection.
    I mean all the files to be send can be saved at a common location and basis file name the attachment can be picked up against each recipient.

    Please help.

    Rukshi

    Reply
    • Vishwamitra Mishra

      Hi Rukshi,
      Glad that you liked the article.
      Meanwhile to solve your problem, you can refer to my Send Email Tutorial Page where you can find all different ways to send an email with/without attachment etc.
      You can read different articles which I have written around folders and files : http://learnexcelmacro.com/wp/2011/11/how-to-get-list-of-all-files-in-a-folder-and-sub-folders/

      Let me know if you are able to find the solution for your problem explained above.

      Reply
      • Rukshi

        Thanks for taking out the time to reply me,
        I am very new with macros, it would be helpful if you can help me with the macro file for sending out emails to different people with one or more than one attachment saved in one folder.
        Right now I am using the below macro, please suggest what changes can be done here so that it fetches the singular or multiple attachment also.

        Public Sub sendWS()
        Application.DisplayAlerts = False
        fpath = Range(“G1”).Value
        On Error GoTo Finally
        For i = 2 To Application.WorksheetFunction.CountA(Columns(2))

        fname = Range(“C” & i).Value & “.” & Range(“H2”).Value
        flname = fpath & fname

        Dim oOutlook As Object
        Dim oEmailItem As MailItem

        On Error Resume Next
        Set oOutlook = GetObject(, “Outlook.Application”)
        If oOutlook Is Nothing Then Set oOutlook = CreateObject(“Outlook.Application”)

        Set oEmailItem = oOutlook.CreateItem(olMailItem)
        With oEmailItem
        ‘.SentOnBehalfOfName = “IndiaExpensemgmt”
        .ReadReceiptRequested = False

        .To = Range(“D” & i).Value
        .CC = Range(“E” & i).Value
        .Subject = Range(“A” & i).Value & “_” & Range(“B” & i).Value & “_” & Range(“H1”).Value
        .Body = “Dear All, ” & vbNewLine & vbNewLine & Sheets(“Email Content”).Range(“A3”).Value & vbNewLine & vbNewLine & Sheets(“Email Content”).Range(“A5”).Value & vbNewLine & Sheets(“Email Content”).Range(“A6”).Value

        TurnSpellingOff

        .Attachments.Add flname
        .Display
        .Send
        ‘Set myInspector = objMail.GetInspector
        ‘myInspector.Activate

        ‘Application.Wait (3)
        ‘ SendKeys “%s”, True
        ‘ SendKeys “%s”, True
        ‘ SendKeys “%s”, True
        ‘SendKeys “%s”, True
        ‘SendKeys “%s”, True
        ‘SendKeys “%s”, True
        ‘SendKeys “{ESC}”, True
        ‘SendKeys “%{y}”, True

        End With
        ActiveCell.Offset(1, 0).Select

        Next i
        Finally:
        OlSecurityManager.DisableOOMWarnings = False

        Set oEmailItem = Nothing
        Set oOutlook = Nothing

        MsgBox “Done”, vbInformation, “Workstream”

        End Sub

        Sub TurnSpellingOff()
        Const KEY_VALUE = “HKCUSoftwareMicrosoftOffice11.0OutlookOptionsSpellingCheck”
        Dim objShell As Object
        Set objShell = CreateObject(“WScript.Shell”)
        objShell.RegWrite KEY_VALUE, 0, “REG_DWORD”
        Set objShell = Nothing
        End Sub

        ——

        In my excel under column C I have to write the file name which is to be attahced, I have read somewhere that if multiple attachement is to be added that one has to write the file name with ; as a separate, but I dont know where in my code above I have to incluce this..

        Please help me…
        Rukshi

        Reply
          • Rukshi

            Thanks so much, this one if great, but here again I have to select multiple attachments 🙁

  24. Zak

    The macro is awesome it can help enormously as I send about 500 emails daily.
    There is one big issue, I keep on getting a prompt saying “A program is trying to send an email on your behalf etc.. ”
    And I must click “Allow” for each email to be sent.
    I tried going in to my outlook mail setting, the allow button is not highlighted by me and in the big company I work for they will not allow to disable..
    What do I do?
    Please help.
    Thank you,
    Zak.

    Reply
  25. Yusuf Shaik

    Hi,

    This is an amazing

    kindly share the password to my email id.

    Reply
  26. Vishesh

    Hello Vishwa,

    Thanks for providing us such a nice tool. But this is not working on 64-Bit systems. Can you please look into this.

    Thanks,
    Vishesh
    visheshgolya@gmail.com
    +91-80056-90366

    Reply
  27. malina

    Hello,

    I’m trying to run this VBA, but the error message is Could not complete the operation. One or more parameter values are not valid.(-2147024809)

    Am I doing something wrong?

    many thanks

    Reply
  28. mayur

    Hi Ankeet,

    It would be great if you can share the VBA password please

    Reply
  29. Asa

    Select which ones to send

    I would like to see if there is a way to select which emails to send. Maybe a checkbox

    Reply
  30. Alaa

    Hi
    I have problem with outlook Email. its not send through it

    Reply
  31. Charlie

    This is brilliant… Is there anyway for it to grab information i require from a Excel spread sheet.. I.E Name.. and import it on to the email template automatically

    Reply
  32. Cooldeath

    Hi,

    Your solution working is great, could you please help with VBA password to customize few things.

    Thanks in advance

    Regards
    CD

    Reply
  33. jafar

    respected sir this your tool is wonderful please share VBA password

    Reply
  34. P C Mishra

    mail ID and Password incorrect coming on dialog box of SMTP Server where I entered my mail id and password. i am using version 3

    Reply
  35. Diqi

    Hi, thank you for the tutorial, i need your help, i try to create a VBA Excell to send an email automatically when i press the button. but i got some error, here’s the error “Object doesn’t support this property or method”.

    here my code

    Sub kirim_email()

    Dim Outl As Object ‘Deklarasi Object
    Dim Msg As Object
    Dim Atch As String

    ‘Set Object Outlook
    Set Outl = CreateObject(“Outlook.Application”)
    Set Msg = Outl.CreateItem(0)
    ‘ Memisahkan Sheet2 untuk Attachment
    ThisWorkbook.Worksheets(“STG_TRX”).Copy
    Atch = ThisWorkbook.Path & “\STG_TRX.xlsx”
    With ActiveWorkbook
    .SaveAs Atch
    .Close 0
    End With
    Set Msg = Outl.CreateItem(1)
    ‘ Memisahkan Sheet2 untuk Attachment
    ThisWorkbook.Worksheets(“STG_TRX_BILLER”).Copy
    Atch = ThisWorkbook.Path & “\STG_TRX_BILLER.xlsx”
    With ActiveWorkbook
    .SaveAs Atch
    .Close 1
    End With
    ‘ isi Item
    Msg.To = Sheet13.Range(“B2”).Value
    Msg.CC = Sheet13.Range(“B3”).Value
    Msg.bcc = Sheet13.Range(“B4”).Value
    Msg.Subject = Sheet13.Range(“B5”).Value
    Msg.HTMLBody = “Dear All, Terlampir data WOW iB ”
    Msg.Attachments.Add Atch = ThisWorkbook.Path & “\STG_TRX.xlsx”
    Msg.Attachments.Add Atch = ThisWorkbook.Path & “\STG_TRX.xlsx”
    Msg.Recipients.ResolveAll
    Msg.Display
    Msg.Send

    End Sub

    in this code i try to copy from another sheet to be an attachment in email (sorry for my spelling word 🙂 ). if i just to sent email with 1 attachment, this code is working, but if i try to sent email with 2 or 3 file together, my code got error.

    kindly need your help. please tell me and teach me for this error (this is my email ibadurrahman.asshiddiqi@gmail.com)

    Thank you for your help,

    Regards,
    Diqi

    Reply
  36. cr

    Hello, I would like to use your template. It is great, but I would like to verify just one thing, is it safe to use? the codes are hidden so I am concerned if it collects data that we may use in your template or if it collects other data from our system.

    Please let me know,

    Thanks a lot,

    Reply
  37. cr

    Hello, I would like to use your template. It is great, but I would like to verify just one thing, is it safe to use? the codes are hidden so I am concerned if it collects data that we may use in your template or if it collects other data from our system.

    Please let me know,

    Thanks a lot,

    Reply

Trackbacks/Pingbacks

  1. Learn Excel Macro Send Multiple Email Tool - Ver 3.0 - [...] of all, I would like to thank you all for appreciating and giving the feedback about Send Multiple Email…
  2. FREE Download : Send Multiple Email Tool - Ver 3.0 - Let's excel in Excel - […] of all, I would like to thank you all for appreciating and giving the feedback about Send Multiple Email…
  3. VBA code for sending email from Gmail or yahoo - LearnExcelMacro.com - […] DOWNLOAD : EXCEL MACRO APPLICATION TO SEND MULTIPLE EMAILS – 2.0 […]

Submit a Comment

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Join and get a FREE! e-Book

Don't miss any articles, tools, tips and tricks, I publish here

You have Successfully Subscribed!

Pin It on Pinterest