Hee! ik heb een probleem, ik ben bezig met een applicatie waarbij ik een mail naar me eigen wil laten verzenden met bestand!
Nu is het probleem:
het is met wel gelukt een email te versturen maar hoe doe ik een bestand erbij?
de code:
Weet iemand hoe ik er een bestand er bij kan stoppen?
Danku!
Rick.
Nu is het probleem:
het is met wel gelukt een email te versturen maar hoe doe ik een bestand erbij?
de code:
Code:
Private Sub Command1_Click()
Set iMsg = CreateObject("CDO.Message")
Set iConf = CreateObject("CDO.Configuration")
Set Flds = iConf.Fields
' send one copy with Google SMTP server (with autentication)
schema = "http://schemas.microsoft.com/cdo/configuration/"
Flds.Item(schema & "sendusing") = 2
Flds.Item(schema & "smtpserver") = "smtp.gmail.com"
Flds.Item(schema & "smtpserverport") = 465
Flds.Item(schema & "smtpauthenticate") = 1
Flds.Item(schema & "sendusername") = "radasdwqwed@gmail.com"
Flds.Item(schema & "sendpassword") = "jehond"
Flds.Item(schema & "smtpusessl") = 1
Flds.Update
With iMsg
.To = "asdasd@hotmail.com"
.From = "Rick <asdsd@hotmail.com>"
.Subject = "Test send with gmail account"
.HTMLBody = Message
.Sender = "Rick"
.Organization = "Rick"
.ReplyTo = "asdaddd@gmail.com"
Set .Configuration = iConf
SendEmailGmail = .Send
End With
Set iMsg = Nothing
Set iConf = Nothing
Set Flds = Nothing
End Sub
Weet iemand hoe ik er een bestand er bij kan stoppen?
Danku!
Rick.