使用来自Excel表格的VBA发送电子邮件,并带有多个收件人 - 拉日期和附件
我正在使用VBA代码从Excel表发送电子邮件:
我使用代码为C列中的每个电子邮件地址生成单独的电子邮件,并带有附加的文件。
我希望将代码添加到:
- 将日期从D列D到电子邮件正文。
我已经为电子邮件的正文提供了我希望日期的代码。
我如何按行获得每个电子邮件的日期。 - 如果列E中有链接,请将附加文件附加到电子邮件中。
这将是代码中已经在代码中的一个。
Excel表中的每一行应使用C列中的电子邮件地址,D列中的日期和附件。
I am using VBA code to send emails from an Excel sheet:
I use code to generate a separate email for each email address in Column C with a file attached.
I am looking to add code to:
- Pull in the date from column D to the body of the email.
I have put in the code for the body of the email where I want the date to go.
How do I get the date for each email row by row. - Attach an additional file to the email IF there is a link in column E.
This would be in addition to the one already in the code.
Each row in the Excel sheet should generate a separate email using the email address in column C, date in column D and attachment in column E.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
假设其余代码有效,只需将块更新为:
assume that the rest of the code works, just update the with-block to: