Ejemplo n.º 1
0
        public static bool SendBugReportEmail(string BugMessage, int bugNumber)
        {
            bool success = false;

            try
            {
                string bookSpadeAdminEmail = "*****@*****.**";
                EmailUtil e = new EmailUtil(bookSpadeAdminEmail, "User Reported Bug: #" + bugNumber, BugMessage);
                success = true;
            }
            catch (Exception e)
            {
                Console.Write("ERROR: failed to send email ---- " + e.Message);
            }

            return success;
        }
Ejemplo n.º 2
0
        //(Respondant, PostedBy, textbook, RespondantEmail, PosterEmail);
        public static bool SendSellerMail(string Respondant, string PostedBy, string textbook, string RespondantEmail, string PosterEmail)
        {
            bool success = false;

            try
            {
                string subject = String.Format("{0} : {1} wants to buy this textbook", textbook, Respondant);
                string body = string.Empty;
                body += String.Format("Hello {0}, <br/><br/>", PostedBy, Environment.NewLine);
                body += String.Format("Congratulations! <br/><br/> {0} wants to buy {1} textbook from you.", Respondant, textbook);
                body += String.Format("Please contact <b>{0}</b> through this email address: <br/><br/><b>{1}</b><br/><br/>", Respondant, RespondantEmail);
                body += "Thank You, <br/>";
                body += "BookSpade Team";

                EmailUtil e = new EmailUtil(PosterEmail, subject, body);
                success = true;
            }
            catch (Exception e)
            {
                Console.Write("ERROR: failed to send email ---- " + e.Message);
            }

            return success;
        }