uchicago-mobi / 2015-Spring-Forum

1 stars 0 forks source link

finding file URL returns nil #91

Closed xiaoyifan closed 9 years ago

xiaoyifan commented 9 years ago

I store the data from iOS app by using plist and get the URL by using following code. [[NSFileManager defaultManager] containerURLForSecurityApplicationGroupIdentifier: appGroup];

However, I can see things saved with no problem, but cannot be fetched in the watch extension. the returning value is nil. Any idea on this?

tabinks commented 9 years ago

Make sure that the data is writing correctly. Try reading the data from the app to make sure you can see it. What you have here looks ok.

xiaoyifan commented 9 years ago

ahh.....it's solved, I forgot to open the App Group switch in watchkit

xiaoyifan commented 9 years ago

Thanks!