Xcode Build Error Reading Plist on device
This is the message I get from Xcode when I do a device build to the debug configuration. The .plist is a question/answer file for a game. Works great in the simulator.
<com.apple.tools.product-pkg-utility>: error reading property list '/Users/Kriolu/Documents/HurryHome2D/Resources/DemoQuestions.plist' - expecting 'NSDictionary', found 'NSCFArray'
Here is the code:
NSString *path = [[NSBundle mainBundle] pathForResource:@"DemoQuestions" ofType:@"plist"];
questions = [[NSMutableArray alloc] initWithContentsOfFile: path];
The root of the .plist file is Array not Dictionary. The files is in the Resources directory and the name is spelled correctly and case-sensitive. I only read this file, so I think accessing from the bundle is ok.
Can not figure out what the source of this problem is.
thanks,
|