Esempio n. 1
0
        public void SendMailWithAttachment_Test()
        {
            var path = @"D:\Test.txt";

            var fs = new FileStream(path, FileMode.Open, FileAccess.Read);
            var attachmemts = new List<Tuple<Stream, string>> { Tuple.Create((Stream)fs, "MyTest.xlsx"), Tuple.Create((Stream)fs, "MyTest.txt") };
            var manager = new MailManager("Gear Mail Test", "Test", new[] { "*****@*****.**" }, attachmemts);
            manager.Send();
        }
Esempio n. 2
0
 public void SendMail_Test()
 {
     var manager = new MailManager("Gear Mail Test", "Test", "*****@*****.**");
     manager.Send();
 }
Esempio n. 3
0
 protected void SendMail(string subject, string body, string[] tos, string[] ccs, string[] bccs, IEnumerable<Tuple<Stream, string>> attachments)
 {
     var manager = new MailManager(subject, body, tos, ccs, bccs, attachments);
     manager.Send();
 }
Esempio n. 4
0
 protected void SendMail(string subject, string body, string[] tos, string[] ccs, string[] bccs, string[] attachments)
 {
     var manager = new MailManager(subject, body, tos, ccs, bccs, attachments);
     manager.Send();
 }