Plist array , cannot change dictonaries inside

Posted by Andy Jacobs on Stack Overflow See other posts from Stack Overflow or by Andy Jacobs
Published on 2010-04-20T14:39:46Z Indexed on 2010/04/20 14:43 UTC
Read the original article Hit count: 303

Filed under:
|
|
|
|

i have a plist that's at its root an array with dictonaries inside it.

i load a plist from my recourses as an NSMutableArray.

[NSMutableArray arrayWithContentsOfFile:[[NSBundle mainBundle] pathForResource:@"Filters" ofType:@"plist"]]

i store it into nsuserdefault because it has to be persistent between startups.

[[NSUserDefaults standardUserDefaults] setObject:array forKey:@"filters"];

but i can't change the dictonaries in the array because they are not mutable. how can i make them mutable?

© Stack Overflow or respective owner

Related posts about iphone

Related posts about mutable