G
Guest
Hi,
I got this code from the web, but i can't get it to work. Is there any special setting on my local WinXP machine to make it works? I have enabled the IIS-SMTP Service. Anything else?
Dim mailMsg As New CDO.Message
Dim mailConfig
Set mailConfig = CreateObject("CDO.Configuration")
mailConfig.Fields(edoSMTPServer) = "localhost"
mailConfig.Fields(edoSendUsingMethod) = cdoSendUsingPort
mailConfig.Fields.Update
mailMsg.configuration = mailConfig
mailMsg.To = "(e-mail address removed)"
mailMsg.From ="(e-mail address removed)"
mailMsg.Subject = "testing mail"
mailMsg.AddAttachment("c:\Temp\test.txt")
mailMsg.Send
I got this code from the web, but i can't get it to work. Is there any special setting on my local WinXP machine to make it works? I have enabled the IIS-SMTP Service. Anything else?
Dim mailMsg As New CDO.Message
Dim mailConfig
Set mailConfig = CreateObject("CDO.Configuration")
mailConfig.Fields(edoSMTPServer) = "localhost"
mailConfig.Fields(edoSendUsingMethod) = cdoSendUsingPort
mailConfig.Fields.Update
mailMsg.configuration = mailConfig
mailMsg.To = "(e-mail address removed)"
mailMsg.From ="(e-mail address removed)"
mailMsg.Subject = "testing mail"
mailMsg.AddAttachment("c:\Temp\test.txt")
mailMsg.Send