Re: Error with GURL/GURL
Re: Error with GURL/GURL
- Subject: Re: Error with GURL/GURL
- From: Bernard Desgraupes <email@hidden>
- Date: Mon, 21 Jun 2004 21:44:54 +0200
Christopher Nebel wrote:
See <http://developer.apple.com/documentation/Carbon/Reference/
LaunchServicesReference/LSRReference/function_group_2.html#//apple_ref/
c/func/LSOpenCFURLRef>, and also its slightly more complicated but
more flexible sibling LSOpenFromURLSpec at
<http://developer.apple.com/documentation/Carbon/Reference/
LaunchServicesReference/LSRReference/function_group_2.html#//apple_ref/
c/func/LSOpenFromURLSpec>. If you need anything opened, Launch
Services is your friend.
Yes it's just great. I replaced my AppleEvent by just two lines of code
like this to achieve what I need. It calls Safari or Mail just fine
depending on the Url I apply it to:
theCFUrl = CFURLCreateWithBytes(kCFAllocatorDefault, (const UInt8 *)
urlCString, strlen(urlCString),
CFStringGetSystemEncoding(), NULL);
error = LSOpenCFURLRef(theCFUrl, &outLaunchedURL);
Thanks very much for the help,
Bernard
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.