View Single Post
 
Old 02-26-2025, 08:13 AM
BigMac'ro BigMac'ro is offline Windows 10 Office 2016
Novice
 
Join Date: Feb 2025
Posts: 9
BigMac'ro is on a distinguished road
Default

Thank you! I actually just found a solution, it appears it's quite similar to yours :


Code:
doc.Content.Copy


With objMail
        .Display
        .To = strTo
        .CC = strCC
        .BCC = strBCC
        .Subject = strSubj
        .BodyFormat = olFormatHTML
        
        Set olInsp = .GetInspector
        Set wdDoc = olInsp.WordEditor
        Set oRng = wdDoc.Range(0, wdDoc.Characters.Count)
        If Not (wdDoc Is Nothing) Then
            wdDoc.Content.Paste
        End If
        
        For a = LBound(strIndivAttach) To UBound(strIndivAttach) ' several attachements
            If Dir(strIndivAttach(a)) <> "" Then
                .Attachments.Add (strIndivAttach(a))
            End If
        Next a
        '.Send 
    End With
I used .Content.Copy, you use .Range.Copy. I'll also try your way to see if I can add the default Outlook signature. I did not find a way to do that yet, except pasting the signature in the Word document beforehand (not very elegant).
Reply With Quote