Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSNumberFormatter localization bug?



Hi,

I have some trouble with localization, I have set OS X to English as
prefered language and all time / number localizations to German.

I displayed a number using NSTextField and setDoubleValue:, it worked
fine ([x.setDoubleValue:3.5] results in 3,5 on the screen).

Then I needed to encapsulate the code for calculating the number and
tried to format it with NSNumberFormatter, I even used
setLocalizesFormat: with YES but always got a point as decimal
separator... (I tried several format strings, even an empty one)

At the moment I use

calcResult.resultString=[[NSNumber
numberWithDouble:evalResult.resultValue] stringValue];

what still give me a point as decimal separator!@#

any ideas?


Markus

[demime 0.97c removed an attachment of type text/x-vcard which had a name of mlehmann.vcf]




Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.