public static string GetRfc2822FormattedAddress(string emailAddress, string name) { // RFC 2821 - The domain part of email address is case insensitive but the email address is case sensitive var safeName = Regex.Replace(name, @"[""\<\>]", String.Empty); safeName = GeneralUtility.AsciiToHex(safeName); return(String.Format("\"{0}\" <{1}>", safeName, emailAddress)); }