Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public void SendMail()
- {
- try
- {
- SmtpClient MailServer = new SmtpClient("smtp.gmail.com", 587);
- MailServer.EnableSsl = true;
- MailServer.Credentials = new System.Net.NetworkCredential("vitezslav.skura@gmail.com", "AppleGoogle970120");
- MailMessage Msg = new MailMessage("vitezslav.skura@gmail.com", "vita.skura@email.cz");
- Msg.Subject = "Service Project";
- Msg.Body = this.Msg_Body;
- MailServer.Send(Msg);
- }
- catch (Exception e)
- {
- throw new ApplicationException();
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement