Is there any method for “formatting” an int this way:
Lets say I have a int with value 1000000. I want to set this int in a textview, but i want it to show like this 1 000 000 or 1.000.000. How can I do this ?
Is there any method for formatting an int this way: Lets say I have
Share
See this tutorial. I think it should teach you how to format your numbers, both integer and real numbers.
As for your specific question see here:
This prints out:
This is modified code from the examples in the same site. I demonstrate the format you wanted.