Introduction
When it comes to string manipulation, the StringBuilder class becomes a powerful tool in any developer’s arsenal. However, in B4A (Basic4Android), the built-in StringBuilder has its limitations.
The Issue with B4A’s Default StringBuilder
Read-Only Length:
B4A’s default...
Given global StringBuilder variable sb one can Append new strings as sb.Append("string"). There is a complementary operator sb.Remove(FirstIndex, LastIndex) which can extract a string from the middle of a string. But the Guides say that the character position identified as LastIndex is not...
Ola
I hope my example here makes sense. There seems to be a scope collision between a stringbuilder defined at class_globals and one defined at sub level when the variable name is the same.
In the class I have added 2 subs, Join and Join1 to demo this, my global variable name is sb and the...
It would be helpful if the StringBuilder had a method that would add a new line automatically.
Current Way:
SB.Append("Hello").Append(CRLF).Append("World").Append(CRLF).Append("!")
With the AppendNewLine method, the above would be shortened to this...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.