Sending Email W/ Multiple Recipients (Or CC) and Set High Importance - VBA

eseelhammer

New Member
Joined
Jun 16, 2015
Messages
1
Hello! I wrote this macro a while back and have been slowly modifying it. To be honest I am very new to VBA and have little experience.

I was hoping to edit this code so that the email is sent to multiple recipients (or CC another, either works) and also set High importance on the email

The code is as follows..

Sub ExecSubmitFile()
'
' EmpSubmitFile Macro

If Range("r1") = "" Then
MsgBox ("The name field cannot be blank. Please complete the top of the order form.")
Range("r1").Select

Else

If Range("s2") = "" Then
MsgBox ("The Location field cannot be blank. Please complete the top of the order form.")
Range("s2").Select

Else

If Range("r3") = "" Then
MsgBox ("The Department field cannot be blank. Please complete the top of the order form.")
Range("r3").Select

Else

Dim wb1 As Workbook


Dim address, Name, Loc

address = Range("l3").Hyperlinks(1).address
address = Mid(address, 8)
Name = Range("r1").Value
Loc = Range("s2").Value

Set wb1 = ActiveWorkbook

wb1.SendMail address, "EXECUTIVE Order - " & Name & " " & Loc, True


On Error Resume Next



With OutMail
.display
.OriginatorDeliveryReportRequested = True
.ReadReceiptRequested = False

End With
On Error GoTo 0



With Application
.ScreenUpdating = True
.EnableEvents = True
End With
Range("A1").Select
ActiveWorkbook.Close
End If
End If
End If
End Sub
 

Excel Facts

Did you know Excel offers Filter by Selection?
Add the AutoFilter icon to the Quick Access Toolbar. Select a cell containing Apple, click AutoFilter, and you will get all rows with Apple

Forum statistics

Threads
1,203,487
Messages
6,055,713
Members
444,810
Latest member
ExcelMuch

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