iphone - Backup core data -
i want backup core data database. i've read need save sqlite file. i'm still not sure if that's though. either way, i've been trying save sqlite file i'm not sure how that. think can using code below. not sure go next.
groupappdelegate *appdelegate= (groupappdelegate *)[[uiapplication sharedapplication] delegate]; nsurl *storeurl = [[appdelegate applicationdocumentsdirectory] urlbyappendingpathcomponent:@"group.sqlite"]; nsdata *sqlitedata = [[nsdata alloc] initwithcontentsofurl:storeurl];
- how save file?
- do have make nsdata?
i have setup connect dropbox , need save core data there.
if have nsurl handle sqlite file, don't need convert nsdata or anything. there various ways retrieve file device: a) have emailed attachment. (look @ mfmailcomposeviewcontroller) b) transfer file using dropbox apis dropbox account. @ dropbox apis c) transfer file using itunes. there's way of doing this, don't have reference @ moment.
Comments
Post a Comment