Re: Replace object at key path in NS[Mutable]Dictionary

Jonathan Taylor

I can load the plist file as an NSMutableDictionary, but it seems that only makes the top level dictionary mutable. The dictionaries-within-dictionaries are still immutable. 

Have you tried using NSPropertyListSerialization with the NSPropertyListMutableContainers option? That should make all the nested dictionaries/arrays mutable.

Thankyou Jens (and also Jon) for your reply. That was just what I was hoping for - an API that I didn’t even know where to look for (though obvious in retrospect!). That should do very nicely.

Join to automatically receive all group messages.