I would suggest there is something basic and really important missing from B4A.
You NEED some way of converting the string to an integer or numeric variable otherwise you will find users will keep coming up against this generic error message 'NUMBERFORMATERROR'. Frankly, it shouldn't be this complicated to use or access a number held in a string.
A number held in a string is only really easily used as a string (in printing it out in a message box, for example. When you actually come to USING it as a number you get errors all over the place. I even get errors when I try to copy the number value from the string variable/array into an INT variable!
As you can only read numeric values from a file into a string or string array we need a way of using this string.
The 'numberformaterror' message is useless as it is a generic, no information message. It tells us nothing that will help us see why our code isn't working. It seems to always come up when trying to use a number held in a string.
You NEED some way of converting the string to an integer or numeric variable otherwise you will find users will keep coming up against this generic error message 'NUMBERFORMATERROR'. Frankly, it shouldn't be this complicated to use or access a number held in a string.
A number held in a string is only really easily used as a string (in printing it out in a message box, for example. When you actually come to USING it as a number you get errors all over the place. I even get errors when I try to copy the number value from the string variable/array into an INT variable!
As you can only read numeric values from a file into a string or string array we need a way of using this string.
The 'numberformaterror' message is useless as it is a generic, no information message. It tells us nothing that will help us see why our code isn't working. It seems to always come up when trying to use a number held in a string.