How to send data from Iphone to Watchkit in OS2 in SWIFT
问题 I want to send a dictionary from iPhone to Watchkit in watchOS 2. In watchOS 1 it works fine for me with appgroups but in watchOS 2 I know that we have to use WCSession but I don't know how to use it. Please help me find the solution. 回答1: This blog post should help you out. From that post: First, you'll create and activate a WCSession like so: if (WCSession.isSupported()) { let session = WCSession.defaultSession() session.delegate = self session.activateSession() } For transferring a