Line 1
Line 2
Line 3
Line 4
Line 5
<<Empty line>>
Line 7
Line 8
Line 9
Line 10
<<Empty line>>
<<Empty line>>
我有一个富文本框来显示 10 行,但是数据库中的数据有超过 10 行的 ex。
我需要删除大于 10 的空行并保留 10 之间的任何空行吗?
所以预期的结果应该是
Line 1
Line 2
Line 3
Line 4
Line 5
<<Empty line>>
Line 7
Line 8
Line 9
Line 10
String.IsNullOrEmpty(RichTextBoxr.Lines[Count]) => This if i use, it detects out the last line(in this example 12) and keeps the 11th empty line, which i don't want. Any help?