Send multiple mails with required body of the mail, Attachment, Subject of the mail to specific mail address

Rohith1324

Board Regular
Joined
Feb 27, 2018
Messages
114
Hi,

I have one excel where I have the below details and I'm looking for 1 Click email is sent to all ( Each line one mail to be sent ).

Email BodySubject lineAttachment location ( Path )"To" Mail address"CC" Mail address

Request to someone please help me in automating this.

Regards,
Rohith M
 
Code:
picName = c.Offset(0, 2).Value
if picName="" then
  c.Offset(0, 5).Value = "failed"
else

' HERE THE REST FROM SET OutlookApp
' TO NEXT c

end if
 
Upvote 0

Excel Facts

When they said...
When they said you are going to "Excel at life", they meant you "will be doing Excel your whole life".
Code:
picName = c.Offset(0, 2).Value
if picName="" then
  c.Offset(0, 5).Value = "failed"
else

' HERE THE REST FROM SET OutlookApp
' TO NEXT c

end if

I just wanted to add what ever is there in "Column 3" in HTML Body.

can we do that
 
Upvote 0
Do you want to add attachment path into body of email?

as you wish;
Code:
.HTMLBody = .HTMLBody & "<br>" & c.Offset(0, 2).Value
 
Upvote 0
Do you want to add attachment path into body of email?

as you wish;
Code:
.HTMLBody = .HTMLBody & "<br>" & c.Offset(0, 2).Value

I need one more help in this code.

if 5th Column in my table has the value "ME" then the below code should execute :

.HTMLBody = .HTMLBody & "<br>ExcelAutomat"

IF the 5th Column in my table shows the value " Team" then the below should reflect as :

.HTMLBody = .HTMLBody & "<br>ExcelAutomatTeam"

can you please help
 
Upvote 0
I believe that only ME & TEAM are option:

Code:
.HTMLBody = .HTMLBody & "<br>ExcelAutomat" & IIf(c.offset(0,4).value = "ME", "", "TEAM")
 
Upvote 0

Forum statistics

Threads
1,223,247
Messages
6,171,007
Members
452,374
Latest member
keccles

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top