Adding a signature or image after body of text ??

JamesStag

New Member
Joined
Jul 25, 2018
Messages
18
Hi if some one could please help me add a signature or image to this code i would be very grateful.

Code:
Sub twosaves()

 Sheets("Quote").Select
 ActiveSheet.ExportAsFixedFormat Type:=xlTypePDF, _
        filename:="C:\Users\James\Documents\Excel Test Folder\Quotes PDFs Test\" & _
        Worksheets("Details").Range("C11").Value & ".pdf", _
        OpenAfterPublish:=False
        
    Worksheets("Details").Select
        Range("C11").Select
        ActiveCell.Value = ActiveCell.Value + 1
            
    Sheet1.SaveAs "C:\Users\James\Documents\Excel Test Folder\" & _
        "Quotes Invoices Spread Sheets\" & _
        Worksheets("Details").Range("C27").Value & ".xlsm", _
        xlOpenXMLWorkbookMacroEnabled
         Dim strPath As String, strFName As String, Signature As String
   
   

   'Create the PDF
    Worksheets("Quote").ExportAsFixedFormat Type:=xlTypePDF, filename:=PdfFile, Quality:=xlQualityStandard, IncludeDocProperties:=True, IgnorePrintAreas _
    :=False, OpenAfterPublish:=False
   

 'Create PDF of active sheet only
    strPath = Environ$("temp") & "\" 'Or any other path, but include trailing "\"
   
    strFName = ActiveWorkbook.Name
    strFName = Left(strFName, InStrRev(strFName, ".") - 1) & "_" & ActiveSheet.Name & ".pdf"
   
    Worksheets("Quote").ExportAsFixedFormat Type:=xlTypePDF, filename:= _
        strPath & strFName, Quality:=xlQualityStandard, _
        IncludeDocProperties:=True, IgnorePrintAreas:=False, OpenAfterPublish:=False
   
   ' Select the range of cells on the active worksheet.
    
   
   ' Show the envelope on the ActiveWorkbook.
   ActiveWorkbook.EnvelopeVisible = True
  
   ' Set the optional introduction field thats adds
   ' some header text to the email body. It also sets
   ' the To and Subject lines. Finally the message
   ' is sent.
   On Error Resume Next
   With ActiveSheet.MailEnvelope
      .Item.To = Range("C8").Value
      .Item.Subject = "Stag Arborists"
      .Item.Body = Worksheets("sheet1").Select.Range("B2").Value
      .Item.Attachments.Add strPath & strFName
      .Item.send
   End With
End Sub
 

Excel Facts

Back into an answer in Excel
Use Data, What-If Analysis, Goal Seek to find the correct input cell value to reach a desired result

Forum statistics

Threads
1,214,430
Messages
6,119,443
Members
448,898
Latest member
drewmorgan128

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