C# that splits the string by row then removes last 5 lines
var stringList = strng.Split(new string[]{Environment.NewLine}, StringSplitOptions.None).toList();
return stringList.RemoveRange(StringList.Count - 5, 5);
3
solved trim new line at the end of html string