Re: Launch with bundle fails the first time
Re: Launch with bundle fails the first time
- Subject: Re: Launch with bundle fails the first time
- From: leenoori <email@hidden>
- Date: Sat, 9 Dec 2006 12:35:03 +0100
El 9/12/2006, a las 9:56, Trygve Inda escribió:
You know the location of the application, don't make the system
look for it.
Use any of the NSBundle methods to construct the path:
- (NSString *)pathForResource:(NSString *)name ofType:(NSString *)
extension
- (NSString *)resourcePath
NSURL *appURL = [NSURL fileURLWithPath:[NSString
stringWithFormat:@"%@/Contents/FolderForApps/MySubApp.app",
[[NSBundle
mainBundle] bundlePath]]];
[[NSWorkspace sharedWorkspace] openURL:appURL];
Regards,
Conor
http://www.bruji.com/
Same situation... I lose these options.
options:(NSWorkspaceLaunchOptions)options
additionalEventParamDescriptor:(NSAppleEventDescriptor *)descriptor
launchIdentifier:(NSNumber **)identifier
Why don't you try the first one and if it fails fall back to the
alternative?
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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