简体   繁体   中英

Launch watchOS2 app from iOS app

I have a simple interface with 3 buttons in iOS part (these should be shown on an iPhone, not on watches) and upon clicking on a button I want to set up a specific version of watch app (depending on button clicked, watch OS should use different data for its execution).

First I am not sure how to trigger watch app execution from iOS app part of the code. Second, I need to know how to pass the data about the button clicked. I read several tutorials on watchOS2, but they are talking mostly about how to make watch app, that is already running on apple watches, respond to events - that's not what I need. Are there any tutorials?

Could anyone, please, share some links/suggestion?

You're dangling on the edge of Apple-acceptability, but here's how I'd do it: Make your three apps. With your iOS button, send a notification to the app which you want to open. Within that notification have a button that allows the user to open the app.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM