Re: Creating NSURL from Apple Event string
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