Click here to Skip to main content
15,881,413 members
Articles / Desktop Programming / System
Alternative
Tip/Trick

Using Gmail Account to Send Emails With Attachment

Rate me:
Please Sign up or sign in to vote.
4.00/5 (1 vote)
29 Mar 2011CPOL 12.1K   4   1
Hello Abdur,Helpful article on using Gmail to send mail. Added the following "using" statements to my code:System.Net for NetworkCredentialSystem.Net.Mail for MailMessage and AttachmentSystem.IO for adding a OpenFileDialogAlso modified my code to send with...
Hello Abdur,

Helpful article on using Gmail to send mail.

Added the following "using" statements to my code:

System.Net for NetworkCredential
System.Net.Mail for MailMessage and Attachment
System.IO for adding a OpenFileDialog


Also modified my code to send with newmsg.SendAsync();

Regards,
David

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



Comments and Discussions

 
GeneralDont you mean System.Windows.Forms for OpenFileDialog? Pin
charles henington4-Apr-11 22:58
charles henington4-Apr-11 22:58 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.