Hallo Leute
Wie könnte man bitte bei dem Makro den Fehler abfangen,wenn KEIN "Microsoft Office Qutlook oder Outlook Express am PC installiert ist.
Gruß Heinz
Option Explicit
Sub MailSenden()
Dim StrName As String
Dim objOutlook As Object
Dim objMail As Object
Set objOutlook = CreateObject("Outlook.Application")
Set objMail = objOutlook.CreateItem(0)
StrName = UserForm2.TextBox10.Value
With objMail
.To = StrName
'.Subject = "Betreff (Testmail) ..."
'.Body = " Sehr geehrte Damen und Herren ... "
.ReadReceiptRequested = True
.Display ' oder direkt Send
End With
Set objOutlook = Nothing
Set objMail = Nothing
End Sub