Thursday, May 7, 2009

How to attach PDF when sending mail?

Attachment when sending mail :-
string attachment = Session["PdfFileName"].ToString();
Attachment att = new Attachment(attachment);
message.Attachments.Add(att);
SmtpClient emailClient = new SmtpClient(SMTPServer);

No comments:

Post a Comment