• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: 'nuther dumb question
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: 'nuther dumb question


  • Subject: Re: 'nuther dumb question
  • From: Graham Cox <email@hidden>
  • Date: Sat, 17 May 2014 13:41:20 +1000

On 17 May 2014, at 9:46 am, William Squires <email@hidden> wrote:

> how do I convert the contents of an NSString object into an NSData object? Why? Because -[NSFileHandle writeData:(NSData *)] takes an NSData object, not an NSString object. Arrrgghhhh. :(


BTW, is there some reason you can't just use [NSString writeToURL:atomically:encoding:error:]?

Presumably on iOS this method does the work using a minimum of additional memory.

--Graham



_______________________________________________

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


References: 
 >'nuther dumb question (From: William Squires <email@hidden>)

  • Prev by Date: Re: 'nuther dumb question
  • Next by Date: Re: NSSharingService with Animated GIFs?
  • Previous by thread: Re: 'nuther dumb question
  • Next by thread: making NSView firstResponder/key
  • Index(es):
    • Date
    • Thread