Re: 'nuther dumb question
Re: 'nuther dumb question
- Subject: Re: 'nuther dumb question
- From: Sixten Otto <email@hidden>
- Date: Fri, 16 May 2014 18:10:38 -0700
On Fri, May 16, 2014 at 4:46 PM, William Squires <email@hidden>wrote:
> Why doesn't NSData have a +[NSData dataWithString:(NSString *)] or
> -[NSData initWithString:(NSString *)] method? i.e. how do I convert the
> contents of an NSString object into an NSData object?
Try -[NSString dataUsingEncoding:] or
-[NSString dataUsingEncoding:allowLossyConversion:] ?
Sixten
_______________________________________________
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