ERFORDERLICHE
OBJEKTE
1 Commandbutton (Command1)
FORM-CODE
Private Declare Function ShellExecute Lib "Shell32.dll" _
Alias "ShellExecuteA" (ByVal hWnd As Long, _
ByVal lpOperation As String, ByVal lpFile As String, _
ByVal lpParameters As String, ByVal lpDirectory As String, _
ByVal nShowCmd As Long) As Long
Private Sub Mail(eMail As String, Optional Subject As String, _
Optional Body As String)
Call ShellExecute(0&, "Open", "mailto:" + eMail + _
"?Subject=" + Subject + "&Body=" + Body, "", "", 1)
End Sub
Private Sub Command1_Click()
Dim Nachricht As String
Nachricht = "Hallo" & "%0D%0A" & "Du da !"
Call Mail("[email protected]", "Ein Betreff", Nachricht)
End Sub
|