Re: NSNumberFormatter not working for me ?
Re: NSNumberFormatter not working for me ?
- Subject: Re: NSNumberFormatter not working for me ?
- From: Kyle Sluder <email@hidden>
- Date: Tue, 13 Apr 2010 16:01:34 -0700
On Tue, Apr 13, 2010 at 3:39 PM, Keary Suska <email@hidden> wrote:
> I think the issue remains that the format you are passing is not considered a valid format, and is getting ignored. You can confirm this by providing a valid number format for comparison. I tend to use a custom formatter for this purpose, keeping the phone number as a string. It is more robust and allows for non-U.S. number that may begin with 0.
Hear, hear.
Things like phone numbers, zip codes, and order numbers aren't really
numbers. They're labels composed of digits. Numbers are typically
useful for quantities, and that's where number formatters are
appropriate. Custom formatters that convert from strings to strings
are the more appropriate choice for telephone numbers and the like.
--Kyle Sluder
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden