B4J Question Is the StringFunctions library available for B4J?

B4JExplorer

Active Member
Licensed User
Longtime User
Hi,

Is StringFunctions available for B4J? It's referenced at

http://www.b4x.com/android/help/stringfunctions.html


, and was hoping there's a compatible version.

I specifically need it for extracting area codes and other parts of written phone numbers, which vary in formats like '9999999999' and '999-999-9999', without having to write any custom Select code.
 

B4JExplorer

Active Member
Licensed User
Longtime User
You don't need any library to parse text.

Thanks Erel, but it wasn't really about parsing text. That's straightforward enough.

For some reason, I thought that the Stringfunctions class had some functionality specifically dedicated towards phone numbers. But that was obviously some other site.

But yeah, it turns out that the entry form which produces these numbers, forces an area code, and only accepts U.S. numbers. So, all I had to do was sPhone.Replace() dashes, spaces, and parentheses with blanks, generating a canonical form 9999999999, which was then parsed out easily.

All set, thanks.
 
Upvote 0
Top