How can I run one app from another app in iphone?

前端 未结 4 1304
甜味超标
甜味超标 2021-01-29 09:06

On some app , I see when one link touched , use safari for open link and quit from current app. I want use from this feature for run messages app from other app. Can I do this?

4条回答
  •  既然无缘
    2021-01-29 09:41

    You need to use -[UIApplication openURL:]. For example, you can use

    [[UIApplication sharedApplication] openURL: [NSURL URLWithString: @"http://www.stackoverflow.com"]]
    

    Note this will also switch to the new app. An application can register the URL schemes it supports using its plist.

提交回复
热议问题