2015-07-01, 21:58
I want to format a number (eg 100000) in the regional settings from the operating system (EN: 100,000 or DE: 100.000).
I tried the python locale module but the xbmc environment does not provide the regional settings.
this will work in a normal python environment but in an xbmc addon this will print 100000 regardless of the regional setting.
what did I wrong?
I tried the python locale module but the xbmc environment does not provide the regional settings.
Code:
import locale
locale.setlocale( locale.LC_ALL, '' )
'{:n}'.format(1000000)
this will work in a normal python environment but in an xbmc addon this will print 100000 regardless of the regional setting.
what did I wrong?