• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Adding pictures from excel into email

Raymond

New Member
Good Day

I am trying to get users to email sleected fields in excel by clicking a button.
The user is reaquired to paste a screenshot into excel.
When the user clicks send it should either attach or add the picture to the body.
How would I do this, as most scripts are written for chart objects and I am not able to change it to select the picture instead?

This is my code
Code:
Sub Bridge_Q()
 
Dim LR As Long
    LR = Range("AA" & Rows.Count).End(xlUp).Row
    Range("AA" & LR + 1).Value = Range("b2") & " (" & LR & ")"
   
Dim OutApp As Object
Dim OutMail As Object
Dim strbody As String
 
 
strbody = "<H3><B>Good Day</B></H3>" & _
          "Please assist with below query.<br><br>" & Range("b7") & vbCrLf & _
          "<br><br>Please see screenshot.<br><br>"
 
Set OutApp = CreateObject("Outlook.Application")
Set OutMail = OutApp.CreateItem(0)
 
 
On Error Resume Next
 
With OutMail
.Subject = Range("z2") & Range("AA" & LR + 1)
.To = "email@adress1.co.za; " + "email@adress2.co.za"
.CC = Range("z1")
.BCC = "email@adress3.co.za"
.HTMLBody = strbody
.Display
.send
End With
 
On Error GoTo 0
 
    Set OutMail = Nothing
    Set OutApp = Nothing
 
 
End Sub

Thanks
 
Back
Top