public void EmailMessage(IMessage message)
 {
     MessagingForEmailRepository.Send(message.MailMessage);
     Console.WriteLine("Sent e-mail to " + message.MailMessage.To + " with the following text:");
     Console.WriteLine("-----");
     Console.WriteLine(message.MailMessage.Subject);
     Console.WriteLine(message.MailMessage.Body);
     Console.WriteLine("-----");
     if (!String.IsNullOrEmpty(message.Text))
     {
         Console.WriteLine("Notes:");
         Console.WriteLine(message.Text);
     }
     Console.WriteLine("");
 }
        public void EmailMessage(IMessage message)
        {
            MessagingForEmailRepository.Send(message.MailMessage);
            var feedback = new Message
            {
                Type = message.ResponseCode,
                Text = ((Status.StatusGroup(message.ResponseCode) == StatusCode.OK)
                        ?
                        "Sent e-mail to " + message.MailMessage.To + " with the following text:"
                        + "<hr/>"
                        + "<p>" + message.MailMessage.Subject + "</p>"
                        + "<p>&nbsp;</p><article>"
                        + message.MailMessage.Body
                        + "</article><hr/>"
                        :
                        "Unable to send e-mail to " + message.MailMessage.To + "."
                        + "<hr/>ERROR: " + message.ResponseCode.ToString()
                        + "<article>" + message.ResponseText + "</article>"
                        )
            };

            WriteMessage(feedback);
        }