Question

i want to modify entries in custom plist file programmatically.

can anybosy suggest me a way to do that? i have tried modifying values of keys but file is not getting saved..

Was it helpful?

Solution

You don't provide much information as to what you've tried, but I assume from the tag that this is on the iPhone. In addition to Pat's suggestion, make sure that the plist you are trying to edit is not within your app bundle, but located within an editable location like Documents or Library within your sandbox.

OTHER TIPS

I would look at the NSDictionary method:
- (BOOL)writeToFile:(NSString *)path atomically:(BOOL)flag

I'm sure there's a similar method for NSArray.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top