Wish [Wish] StringBuilder new method: AppendNewLine

LWGShane

Well-Known Member
Licensed User
Longtime User
It would be helpful if the StringBuilder had a method that would add a new line automatically.

Current Way:
Code: Copy
SB.Append("Hello").Append(CRLF).Append("World").Append(CRLF).Append("!")

With the AppendNewLine method, the above would be shortened to this:
Code: Copy
SB.AppendNewLine("Hello").AppendNewLine("World").AppendNewLine("!")

And would still output:

Code: Copy
Hello
World
!
 
For now try something like this

Code: Copy
Public sub AppendNewLine(sb as stringbuilder, text as string) as stringbuilder

    sb.Append(text)

    sb.Append(CRLF)

    return sb

End sub
 
Back
Top