2011-02-18 83 views

回答

2
NSString *path = [[NSBundle mainBundle] bundlePath]; 
NSString *dictionaryPath = [path stringbyAppendingPathComponent:@"myplist.plist"]; 

NSDictionary *integerDictionary = [[NSDictionary alloc] initWithContentsOfFile:dictionaryPath]; 

int myInteger1 = [[integerDictionary objectForKey:@"integer1"] intValue]; 
int myInteger2 = [[integerDictionary objectForKey:@"integer2"] intValue]; 
// etc etc 
+0

yupz ..它的工作..謝謝.. – xuanweng 2011-02-18 04:32:52