public static string GetIntroduction(string htmlBody) { var introduction = string.Empty; if (string.IsNullOrEmpty(htmlBody)) { return(introduction); } try { introduction = MailUtil.ExtractTextFromHtml(htmlBody, 200); } catch (RecursionDepthException) { throw; } catch { introduction = (htmlBody.Length > 200 ? htmlBody.Substring(0, 200) : htmlBody); } introduction = introduction.Replace("\n", " ").Replace("\r", " ").Trim(); return(introduction); }