Hallo,

ich will eine EMail erstellen per Makro.

Hier ist der Code:


Dim sPMUA As String
Dim sEmail As String
Dim sSubject As String
Dim sAttachment As String
Dim sBody As String
Dim sMessage As Object
Dim oShell As Object


        oShell = createUnoService("com.sun.star.system.SystemShellExecute")

        sPMUA = "/Applications/Thunderbird.app/Contents/MacOS/thunderbird"
        sEmail = "strunzenol...@gmx.de"
        sSubject = "Ich bin ein Betreff"
        sAttachment="file:///Users/strunz/Documents/Foto.jpeg"
        sBody = "Hallo ich bin der Body"

        sMessage = sPMUA & _
        " -compose to=" & sEmail & _
        ",bcc=user@example.example" & _
        ",subject='" & sSubject & "'" & _
        ",attachment='"& sAttachment & "'" & _
        ",preselectid=id10" & _
        ",body='" & sBody & "'"

         oShell.execute(sMessage)

End Sub

Allerdings erhalte ich folgende Aussage (Objektvariable nicht belegt
(sMessage = sPMUA &_)


Was muss ich tun?


Mfg

Strunzenolwin



-- 
Liste abmelden mit E-Mail an: users+unsubscr...@de.libreoffice.org
Probleme? 
https://de.libreoffice.org/hilfe-kontakt/mailing-listen/abmeldung-liste/
Tipps zu Listenmails: https://wiki.documentfoundation.org/Netiquette/de
Listenarchiv: https://listarchives.libreoffice.org/de/users/
Datenschutzerklärung: https://www.documentfoundation.org/privacy

Antwort per Email an