Re: Rounding to two decimals
Re: Rounding to two decimals
- Subject: Re: Rounding to two decimals
- From: "Louis C. Sacha" <email@hidden>
- Date: Sat, 17 Jul 2004 23:01:50 -0700
Hello...
Use an NSNumberFormatter on the textField with the appropriate format
string. If the rounded value is only for display, you don't actually
need to do the rounding yourself and can just let the formatter take
care of it.
Louis
The text printed in averageLabel is "1.6000000238...". It seems the
rounding is done quite nicely, I'm just wondering why there's such a
strange extension. An idea how I can get rid of this?
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.