Re: NSString ASCII filter
Re: NSString ASCII filter
- Subject: Re: NSString ASCII filter
- From: James Hober <email@hidden>
- Date: Tue, 12 Feb 2008 13:29:10 -0800
On Feb 12, 2008, at 12:04 PM, Sean McBride wrote:
On 2/12/08 11:58 AM, James Hober said:
What is the simplest, reasonably efficient way to determine if an
NSString contains a non-ASCII character
How about:
BOOL foo = [string canBeConvertedToEncoding:
NSASCIIStringEncoding];
Yes! A one liner for simple task. Thanks!
James
_______________________________________________
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