开发者

Question on Utility Application - iPhone SDK

I have this application I made on a utility based app. How would I incorporate this app into a view based application so I can run the code from there.. Like 2 seperate projects in one. I basically want to open/show the utility app in my view based application when I press a button.. Is this po开发者_如何学编程ssible??


You want to implement a URL scheme for the app you want to launch. Then from the calling app have something like this:

NSURL *appUrl = [NSURL URLWithString:@"myapp://foo/bar"];
UIApplication *app = [UIApplication sharedApplication];
if ([app canOpenURL:appUrl]) {
    [app openURL:appUrl];
} else {
    // tell user they need to have this other app installed.
}

More info about how to do this here: http://iosdevelopertips.com/cocoa/launching-your-own-application-via-a-custom-url-scheme.html

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜