Sending email automatically?

mythinky

Member
Joined
Jun 4, 2004
Messages
20
Programming Experience
1-3
Helo, how to automate sending email? I want to automatically send email to some addresses every day? How can i do that?
I build that one for my final project at my college. Please help me.
Thanks in advance.
I am using this code....
try
Dim objEmailMessage As System.Web.Mail.MailMessage
Dim objSMTPServer As System.Web.Mail.SmtpMail
objSMTPServer.SmtpServer = "mail.wefgroup.com"

objEmailMessage = New System.Web.Mail.MailMessage
With objEmailMessage
.To = "someone@wefgroup.com"
.From = "me@yahoo.com"
.Subject = "Helo"
.Body = "I test sending email"

End With

objSMTPServer.Send(objEmailMessage)
catch exc as exception
response.write(exc.innerexception.innerexception.message)
end try
 
I think the simplest way to perform something on a regular basis would be by building a Console Application and running it via the Windows Scheduler. This would cause the program to run, and when it's finished...it would close.

You could build a Windows Application and use the "Timer" function...but the program would have to be running all the time...and may need to be converted to a service in order to run when no one is logged in.

So, as far as simplicity is concerned...the first option would be best.
 
Back
Top