CookieMonster76
Board Regular
- Joined
- Apr 30, 2015
- Messages
- 201
Hi
I have the following in Columns A to D in a spreadsheet
A B C D
Supplier1@xxx.com Supplier 1 £10,000 x
Supplier2@yyy.com Supplier 2 £20,000
Supplier3@zzz.com Supplier 3 £30,000 x
I'd like to automate the sending of an e-mail, but only to those suppliers marked with an x in Column D - I needs to be a new e-mail for each supplier.
I have the code to send an e-mail to a fixed address. Is it possible to change the bold items below to be dynamic and to reference A1, B1 and C1 above?
.Subject = Title
.to = "Supplier1@xxx.com"
.CC = ""
.BCC = ""
.Subject = "Outstanding Invoices"
.Body = "Hi Supplier1" & vbLf & vbLf _
& "You currently owe £10,000." & vbLf & vbLf _
& "Please let me know if you have any queries." & vbLf & vbLf _
& "Thanks" & vbLf & vbLf _
& "Paul" & vbLf & vbLf
And then can I make it loop through and send e-mails to just the ones marked x in one go?
Thanks
Paul
I have the following in Columns A to D in a spreadsheet
A B C D
Supplier1@xxx.com Supplier 1 £10,000 x
Supplier2@yyy.com Supplier 2 £20,000
Supplier3@zzz.com Supplier 3 £30,000 x
I'd like to automate the sending of an e-mail, but only to those suppliers marked with an x in Column D - I needs to be a new e-mail for each supplier.
I have the code to send an e-mail to a fixed address. Is it possible to change the bold items below to be dynamic and to reference A1, B1 and C1 above?
.Subject = Title
.to = "Supplier1@xxx.com"
.CC = ""
.BCC = ""
.Subject = "Outstanding Invoices"
.Body = "Hi Supplier1" & vbLf & vbLf _
& "You currently owe £10,000." & vbLf & vbLf _
& "Please let me know if you have any queries." & vbLf & vbLf _
& "Thanks" & vbLf & vbLf _
& "Paul" & vbLf & vbLf
And then can I make it loop through and send e-mails to just the ones marked x in one go?
Thanks
Paul