1
我需要打开我的ios应用程序的默认时间表骑车屏幕的超级应用程序。现在我正在使用这段代码。但它只是导航用户超级应用程序。如何使用其他ios应用程序的默认日程安排屏幕打开超级应用程序?
if (UIApplication.shared.canOpenURL(NSURL(string:"uber://")! as URL))
{
// if your app is available it open the app
Utilities.openScheme(scheme: "uber://?action=setPickup")
}
else
{
// it redirect to safari, safari directly open the web page on uber application, it does not redirect to app store
//UIApplication.shared.openURL(NSURL(string:"http://m.uber.com/?opneapp")! as URL)
Utilities.openScheme(scheme: "https://itunes.apple.com/us/app/uber/id368677368")
}
在这里,我附上了需求的图像。
我该如何在iOS Swift 3中做到这一点?