ios - How to read sub elements of a plist file -
i having plist file want access 3 elements( item 0, item 1, item 2 ) under under 5k , want store in array. how can ? if 1 know solution please me solve issue. if not clear please post comments replay it.
thanks in advance.
expended form.
the code have used
-(void)selectlevel { plistpath = [[nsbundle mainbundle] pathforresource:@"planlist" oftype:@"plist"]; nsmutabledictionary * plist = [[nsmutabledictionary alloc] initwithcontentsoffile:plistpath]; nsmutabledictionary * specific; nsarray * leveldata = [plist objectforkey:@"5k"]; nsarray *complexity = [leveldata objectatindex:1]; nslog(@"++++++++%@",complexity); (int i=0; i<3; i++) { specific =(nsmutabledictionary *)[leveldata objectatindex:i]; nslog(@"-------%@",specific); } nslog(@"=======-%@",[specific allkeys]); }
out put getting
Comments
Post a Comment