提示:其它语言是由 Google 机器翻译的。 你可以访问 English 版本。
登录
x
or
x
x
马上登记
x

or

如何通过Outlook将电子邮件发送到Excel中的多个收件人?

如果在工作表的一列中有多个电子邮件地址,并且现在想要直接从Excel中向该收件人列表发送电子邮件,而无需打开Outlook。 本文将讨论如何同时向Excel中的多个收件人发送电子邮件。

使用VBA代码将电子邮件发送给Excel中的多个收件人

通过使用VBA代码将电子邮件发送给具有当前工作簿的多个收件人作为附件


将个性化电子邮件发送给具有不同附件的多个收件人:

您订购的 Kutools for Excel's 发电子邮件 功能,您可以根据需要通过Outlook快速向具有不同附件的多个收件人发送个性化电子邮件。 同时,您也可以将消息CC或Bcc发送给特定的人。

doc发送个性化电子邮件18 1


箭头蓝色右泡 使用VBA代码将电子邮件发送给Excel中的多个收件人


您可以使用VBA代码一次向多个收件人发送邮件,请按照以下步骤操作:

1. 按住 ALT + F11 键打开 Microsoft Visual Basic for Applications 窗口。

2. 点击 插页 > 模块,并将以下代码粘贴到 模块窗口.

VBA代码:发送电子邮件给多个收件人

Sub sendmultiple()
'updateby Extendoffice 20160506
    Dim xOTApp As Object
    Dim xMItem As Object
    Dim xCell As Range
    Dim xRg As Range
    Dim xEmailAddr As String
    Dim xTxt As String
    On Error Resume Next
    xTxt = ActiveWindow.RangeSelection.Address
    Set xRg = Application.InputBox("Please select the addresses list:", "Kutools for Excel", xTxt, , , , , 8)
    If xRg Is Nothing Then Exit Sub
    Set xOTApp = CreateObject("Outlook.Application")
    For Each xCell In xRg
        If xCell.Value Like "*@*" Then
            If xEmailAddr = "" Then
                xEmailAddr = xCell.Value
            Else
                xEmailAddr = xEmailAddr & ";" & xCell.Value
            End If
        End If
    Next
    Set xMItem = xOTApp.CreateItem(0)
    With xMItem
        .To = xEmailAddr
        .Display
    End With
End Sub

3。 然后按 F5 键执行此代码,会弹出提示框提醒您选择地址列表,请参阅屏幕截图:

doc发送多个收件人1

4。 然后点击 OK和一个Outlook 留言 - 请写下您的需求,我们尽快为您服务 窗口显示出来后,你可以看到所有选中的电子邮件地址已经被添加到了 字段,然后您可以输入主题并编写您的消息,请参阅截图:

doc发送多个收件人2

5。 完成信息后,请点击 发送 按钮,并且此消息将发送到您的工作表列表中的这些收件人。


箭头蓝色右泡 通过使用VBA代码将电子邮件发送给具有当前工作簿的多个收件人作为附件

如果您需要使用当前工作簿作为附件向多个收件人发送邮件,则可以应用以下VBA代码。

1。 按住 ALT + F11 键打开 Microsoft Visual Basic for Applications 窗口。

2。 点击 插页 > 模块,并将以下代码粘贴到 模块窗口.

VBA代码:用当前工作簿作为附件向多个收件人发送电子邮件

Sub EmailAttachmentRecipients()
'updateby Extendoffice 20160506
    Dim xOutlook As Object
    Dim xMailItem As Object
    Dim xRg As Range
    Dim xCell As Range
    Dim xEmailAddr As String
    Dim xTxt As String
    On Error Resume Next
    xTxt = ActiveWindow.RangeSelection.Address
    Set xRg = Application.InputBox("Please select the arresses list:", "Kutools for Excel", xTxt, , , , , 8)
    If xRg Is Nothing Then Exit Sub
    Set xOutlook = CreateObject("Outlook.Application")
    Set xMailItem = xOutlook.CreateItem(0)
    For Each xCell In xRg
        If xCell.Value Like "*@*" Then
            If xEmailAddr = "" Then
                xEmailAddr = xCell.Value
            Else
                xEmailAddr = xEmailAddr & ";" & xCell.Value
            End If
        End If
    Next
    With xMailItem
        .To = xEmailAddr
        .CC = ""
        .Subject = ""
        .Body = ""
        .Attachments.Add ActiveWorkbook.FullName
        .Display
    End With
    Set xOutlook = Nothing
    Set xMailItem = Nothing
End Sub

3。 粘贴代码后,按 F5 键以运行此代码,并弹出提示框提醒您选择要发送消息的地址,请参阅屏幕截图:

doc发送多个收件人3

4. 然后点击 OK 按钮和一个Outlook 留言 - 请写下您的需求,我们尽快为您服务 窗口显示,所有的电子邮件地址已被添加到 字段,并且您当前的工作簿也已作为附件插入,然后您可以输入主题并编写消息,请参阅屏幕截图:

doc发送多个收件人4

5。 然后点击 发送 按钮将此消息发送到当前工作簿作为附件的收件人列表。


相关文章:

如何通过Outlook从Excel发送个性化群发电子邮件到列表?


Kutools for Excel - 最佳办公生产力工具提高80%的生产力

  • 重用: 快速插入 复杂的公式,图表 以及你以前用过的任何东西; 加密单元格 密码; 创建邮件列表 并发送电子邮件...
  • 超级方程式酒吧 (轻松编辑多行文字和公式); 阅读布局 (轻松读取和编辑大量单元格); 粘贴到过滤范围...
  • 合并单元格/行/列 不丢失数据; 分裂细胞含量; 组合重复的行/列...防止重复的细胞; 比较范围...
  • 选择复制或唯一 行; 选择空行 (所有细胞都是空的); 超级查找和模糊查找 在许多工作簿中; 随机选择......
  • 精确复制 多个单元格而不更改公式参考; 自动创建参考 多张表; 插入项目符号,复选框等等......
  • 提取文本,添加文本,按位置删除, 删除空间; 创建和打印分页小计; 在单元格内容和注释之间转换...
  • 超级过滤器 (将过滤方案保存并应用到其他工作表); 高级排序 按月/周/日,频率等; 特殊过滤器 用粗体,斜体......
  • 结合工作簿和工作表; 根据键列合并表; 将数据拆分为多个表格; 批量转换xls,xlsx和PDF...
  • 超过300强大的功能。 支持Office / Excel 2007-2019和365。 支持所有语言。 在您的企业或组织中轻松部署。 全功能60天免费试用。
kte tab 201905

Office选项卡为Office提供选项卡式界面,使您的工作更轻松

  • 在Word,Excel,PowerPoint中启用选项卡式编辑和阅读,Publisher,Access,Visio和Project。
  • 在同一窗口的新选项卡中打开并创建多个文档,而不是在新窗口中。
  • 通过50%提高您的工作效率,每天为您减少数百次鼠标点击!
官方底部
Say something here...
symbols left.
You are guest ( Sign Up? )
or post as a guest, but your post won't be published automatically.
Loading comment... The comment will be refreshed after 00:00.
  • To post as a guest, your comment is unpublished.
    Jose · 6 months ago
    I have this Code, my problem is that it creates one email for each time the condition is not complete, but i want to put all the info that dont reach the condition in only one email

    Sub EnviarCorreo()
    Dim OutApp As Object
    Dim OutMail As Object
    Dim lLastRow As Long
    Dim lRow As Long
    Dim sSendTo As String
    Dim sSendCC As String
    Dim sSendBCC As String
    Dim sSubject As String
    Dim sTemp As String

    Set OutApp = CreateObject("Outlook.Application")
    OutApp.Session.Logon

    ' Change the following as needed
    sSendTo = ""
    sSendCC = ""
    sSendBCC = ""
    sSubject = "Due date reached"

    Set OutMail = OutApp.CreateItem(0)

    lLastRow = Cells(Rows.Count, 3).End(xlUp).Row
    For lRow = 3 To lLastRow
    If Cells(lRow, 9) <> "S" Then
    If Cells(lRow, 2) <= Date Then

    On Error Resume Next
    With OutMail
    .To = sSendTo
    If sSendCC > "" Then .CC = sSendCC
    If sSendBCC > "" Then .BCC = sSendBCC
    .Subject = sSubject

    sTemp = "Hello!" & vbCrLf & vbCrLf
    sTemp = sTemp & "The due date has been reached "
    sTemp = sTemp & "for this project:" & vbCrLf & vbCrLf


    'THIS IS WHAT I WANT TO REPEAT ON EMAIL BODY
    ' Assumes project name is in column B
    sTemp = sTemp & "ID:"
    sTemp = sTemp & " " & Cells(lRow, 1)
    sTemp = sTemp & " Description: "
    sTemp = sTemp & " " & Cells(lRow, 5)
    sTemp = sTemp & " Please take the appropriate"
    sTemp = sTemp & " action." & vbCrLf & vbCrLf
    sTemp = sTemp & " Thank you!" & vbCrLf
    'UNTIL HERE



    .Body = sTemp
    ' Change the following to .Send if you want to
    ' send the message without reviewing first
    .Display
    End With
    Set OutMail = Nothing

    Cells(lRow, 9) = "S"
    Cells(lRow, 10) = "E-mail sent on: " & Now()
    End If
    End If
    Next lRow
    Set OutApp = Nothing
    End Sub
  • To post as a guest, your comment is unpublished.
    steve · 8 months ago
    Morning,


    I am new to trying to write and use macros in excel. My first attempt was to try and create a subset mass email from a large master list. I cut and pasted the first routine, then tried to use it all it did was highlight the cells I requested. no outlook email was created, what did I do wrong? To expand upon my actual request, I really want to target emails by zip code or other subsets. how do I create a macro that will search a column for a given zip code and create an email with all recipients found?

    thank you

    Steve
  • To post as a guest, your comment is unpublished.
    Vinicius · 11 months ago
    Hi ! Every month i should send the same e-mail for diferent providers, but they should not be in the same e-mail..... how could i send the same e-mail for diferent destinations without everyone in the same e-mail ?
  • To post as a guest, your comment is unpublished.
    James V · 11 months ago
    Any way to use this to send from a shared email? I cannot seem to inset a .SendOnBehalfOf field.
  • To post as a guest, your comment is unpublished.
    Robert Springer · 1 years ago
    How can I do this using the BCC line?
    • To post as a guest, your comment is unpublished.
      skyyang · 1 years ago
      Hi, Robert,
      After running the code, the new message window will be opened, you just need to insert the BCC line under the Option tab, see the following screenshot:


      Hope it can help you, thank you!
  • To post as a guest, your comment is unpublished.
    Shashank · 2 years ago
    Hello,

    Thank you for the code.
    Is there a way i can create a command button on the excel and then by clicking on that button the same excel sheet can be sent to multiple recipients as an attachment.
  • To post as a guest, your comment is unpublished.
    Jake · 2 years ago
    Hi,

    The VBA code is working well for me thank you. Is there any way I could create a cell with a button of sorts which triggers the "select mailing list" pop up?

    Jake
  • To post as a guest, your comment is unpublished.
    Matthew · 3 years ago
    This is awesome, exactly what I want.
    Is there anyway to add a feature where you can add a message to the subject line using code....
    I dont want anything in message box