Xcode decimal keyboad produces different result on simulator vs device

33 views Asked by At

I use NSDecimalNumber in my app to do alot of calculations entered in textboxes. I tested it on the simulator and device ( not sure if it changed in iOS 8 or if i just didn't notice ) but on storyboard I use the decimal keyboard.

When i run the app on the simulator i see a dot (.) on the device i see a comma (,). The simulator takes the correct values e.g. 15.99 is stored as 15.99 but on the device if i enter 15.99 it converts it to 15.00.

What am i doing wrong? If i then go an edit this amount on the device the 2nd time round the decimal part is stored. is there a more reliable way to store the values?

Thanks in advance!

1

There are 1 answers

0
Lorenz Meyer On

You don't have the same format setting on the two devices. Adjust the setting for decimal separator.