读plist,并遍历

NSString* path = [[NSBundlemainBundle]pathForResource:filenameofType:@"plist"];
NSDictionary* dict = [NSDictionarydictionaryWithContentsOfFile:path];
if(dict ==nil) {
NSLog(@"Button: failed to load item file[%@], path=%@", filename, path);
returnnil;
}
NSMutableDictionary* meta = [[dictobjectForKey:@"Meta"]mutableCopy];
    
    
   NSArray*a = [metaallKeys];
   for(idkeyina)
    {
       NSLog(@"this is demo%@",[metaobjectForKey:key]);
    }

你可能感兴趣的:(path,button,file,IOS基础知识)