VB.NET - Windows services to send an Auto email with attachment on it

Asked By Ajay on 02-Apr-13 01:40 AM
Hi All,

I just need to know how we can use services to send an auto email service, at each time interval. email should include an attachment also.

regards
Ajay
Robbe Morris replied to Ajay on 02-Apr-13 08:18 AM
If you are using time intervals, you really should just make this a console app and schedule it in windows task scheduler to avoid tying up resources and threads.

The System.NET.Mail namespace has classes for sending mail.

MailAddress

MailMessage

SmtpClient

Ajay replied to Robbe Morris on 02-Apr-13 10:10 AM
Could you give me any sample code