Take the 2-minute tour ×

I am working on some code that I inherited from a programmer who is no longer with my company. In this code, a few images are encoded as base 64 string, then subsequently stored in NSUserDefaults inside a NSDictionary. The issue I am having is if the application has been killed (i.e. thorugh the mulitasking UI), the dictionary containing the data does not seem to load.

Are Base 64 strings considered a property list objects in Objective-C?

I realize this is NOT the ideal solution for storing data on disk, but this is what I have to work with for the immdeiate future.

share|improve this question
add comment

1 Answer

up vote 0 down vote accepted

Do they show up in the application's plist as string or data? If the latter, they're encoded NSData objects; try using objectForKey: and then -[NSImage initWithData:].

share|improve this answer
That is how I am setting the value. However, they are not being stored as an image later, the data will be sent as part of an http post. –  Mike D Jun 25 '12 at 23:28
Base 64 strings are just strings, so they are property list objects, if that's all you needed to know… –  Wevah Jun 25 '12 at 23:29
add comment

Your Answer


