开发者

How to erase an object saved with NSUserDefaults from disk

Let's say I saved data to disk like this:

[[NSUserDefaults standardUserDefaults] setObject:[N开发者_如何学编程SKeyedArchiver archivedDataWithRootObject:theArray] forKey:@"savedArray"];

How can I erase that from disk?


Try this.

[[NSUserDefaults standardUserDefaults] removeObjectForKey:@"savedArray"];
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜