• 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: Creating NSURL from Apple Event string
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Creating NSURL from Apple Event string


  • Subject: Re: Creating NSURL from Apple Event string
  • From: Nir Soffer <email@hidden>
  • Date: Tue, 10 Oct 2006 21:24:04 +0200


On Oct 10, 2006, at 9:08 PM, a.d. jensen wrote:

How do I figure out what's wrong with "http://www.apple.com"; in a NSString, that isn't wrong when I use @"http://www.apple.com"; directly?

"http://www.apple.com"; is a C-string, while @"http://www.apple.com"; is a NSString (actually private subclass for constant strings).


To create a string from C-string, use stringWithCString:encoding:. Since URL must be ASCII, you can use here NSASCIIStringEncoding.

Best Regards,

Nir Soffer

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >Creating NSURL from Apple Event string (From: "a.d. jensen" <email@hidden>)

  • Prev by Date: MEETING: Reminder - Los Angeles - CocoaHeads October 12th
  • Next by Date: Core Data: Need help with fetch request
  • Previous by thread: Re: Creating NSURL from Apple Event string
  • Next by thread: Re: Creating NSURL from Apple Event string
  • Index(es):
    • Date
    • Thread