watchkit

Invalid Bundle error from iTC, cannot submit app - because 4 swift dylibs fail to embed

自作多情 提交于 2019-12-09 09:48:22
问题 My app runs fine on devices & simulators, but when I submit it, I get the Invalid Bundle - One or more dynamic libraries that are referenced by your app are not present in the dylib search path error emailed to me about half an hour after the upload completes successfully. Following the advice on this thead here, namely running otool -L , I can see that the app's main executable has all of its @rpath/...dylib files in the Frameworks/ folder as expected, but , the appex's executable is missing

WCSession - PayloadTooLarge

爱⌒轻易说出口 提交于 2019-12-09 07:34:25
Apple Documentation shows: PayloadTooLarge - An error indicating that the item being sent exceeds the maximum size limit. This type of error can occur for both data dictionaries and files. Available in watchOS 2.0 and later. Does anyone know what the max size limits are for both these methods are for transferring data from the watch to the phone?: func transferUserInfo(_ userInfo: [String : AnyObject]) -> WCSessionUserInfoTransfer and func transferFile(_ file: NSURL, metadata metadata: [String : AnyObject]?) -> WCSessionFileTransfer I can't find it documented anywhere. Thanks! BootMaker

How to share data using Watch Connectivity when working with Core Data

五迷三道 提交于 2019-12-09 05:22:48
问题 In my iOS application I use Core Data to store data and a fetch request to create an array of NSManagedObject s to display in a UITableView . On the Watch OS I check if WCSession is supported and active a session, then send the iOS application a message from the watchOS extension. When the iOS application receives the message from the watchOS it should send the array of Objects to the watchOS extension to display the data in the WKInterfaceTable , but I am unsure how to do this. Ultimately

Watch Kit: is it possible to vibrate watch programmatically?

半城伤御伤魂 提交于 2019-12-09 05:19:31
问题 Is it possible to vibrate watch while Watch Extension is running? We can do it on iOS in this way (force iPhone to vibrate): AudioServicesPlaySystemSound(kSystemSoundID_Vibrate); I hope there is something similar on WatchKit. Update: I have added issue to Apple radar and recieved the answer: Engineering has determined that your bug report (20019274) is a duplicate of another issue (19025053) and will be closed. 19025053 is still open. Update 2: AudioServicesPlayAlertSound() not working on

WatchKit app submission failure; MinimumOSVersion

蹲街弑〆低调 提交于 2019-12-09 03:11:11
问题 Submitting WatchKit 1.2 companion app, fails during validation with this error: ERROR ITMS-90455 "Invalid WatchKit App Bundle. The value '2.1' for the MinimumOSVersion key in info.plist in bundle 'redactedbundlename.watchkitapp' is not supported" I do cannot find a MinimumOSVersion key in the watch app plist or settings, nor in build settings or plist for the phone app. The only mention of anything "2.1" related is in my build settings: Any ideas to diagnose this issue? 回答1: Fixed it! For

prepareForSegue equivalent in WatchKit

耗尽温柔 提交于 2019-12-09 02:39:53
问题 I have an interface with 2 buttons, both of them call the same interface but with different information. On the traditional interface I use prepareForSegue, but I don't know what's the equivalent one on the WatchKit. 回答1: You can do this in two ways: In your storyboard you set an identifier in your segue: and then you can use contextForSegueWithIdentifier : - (id)contextForSegueWithIdentifier:(NSString *)segueIdentifier { if ([segueIdentifier isEqualToString:@"yourIdentifier"]) { return

Does WatchKit support html? is there is controller like UIWebview?

我是研究僧i 提交于 2019-12-09 01:08:58
问题 Does WatchKit support html? is there is controller like UIWebview ?. My client want to show webpage in a Apple Watch. is this possible ? 回答1: There's no UIWebView in WatchKit (neither WatchOS 1 nor WatchOS 2 ). However, it's fully possible to work around this: You can load the HTML , pick out the relevant content, and display that in for example a Label . This is however not a smart solution, as the website owners can change its layout and render your app useless until you update it. My

Watch OS 2 - How store data on Watch for fully native app?

可紊 提交于 2019-12-08 18:05:00
问题 I need to store about 5 variables on the WatchKit Extension - Watch side Only. The app is going to be completely native, without passing any info to the iPhone. I need the data to persist if the watch is re-booted. The app currently resets to the default variable states upon reboot. I'm not sure what to use. I found information online about using the watch keychain for storing key-value data pairs (username/password), but I don't think that's what I should use here. Appreciate some help. 回答1:

How to hide or remove the time from the Apple Watch status bar?

坚强是说给别人听的谎言 提交于 2019-12-08 17:28:31
问题 How do I hide or remove the small clock from Apple Watch statusbar screen on my app? I searched the web for this but found nothing! I just discovered that Apple will reject your app if you remove that clock, but my app is a watch face itself and doesn't need to display that time. 回答1: As you pointed out, trying to hide or remove the time from the status bar will get your app rejected. There's no way to accomplish what you want to do yet, since Apple doesn't permit developers to create custom

retrieve the text of WKInterfaceLabel in swift

我们两清 提交于 2019-12-08 15:45:22
问题 How can i get the text of label in Swift or Objective-C in WatchKit? The class is not UILabel but it is WKInterfaceLabel. I have also tried to search in class library of apple but there is only three methods are available. 回答1: By reading reference it is not possible you have to maintain track which you set in label looks like apple is very strict about this class you can not create a subclass or direct instance of this. They only talk about how to set the text not about getting text Non of