static string Ellipsify (string str, int max) { if(str.Length > max) return str.Substring(0, max - 1) + "..."; return str; }