If you want to use GDataXMLParser, you can use the following code that works great
The first Impost library file is GDataXMLParser, and then write vbe
-(void)XMLParsing { GdataParser *parser = [[GdataParser alloc] init]; NSString* urlString = @"YOURURL"; NSURL *url = [[NSURL alloc] initWithString:urlString]; [parser downloadAndParse:url withRootTag:@"Category" withTags:[NSDictionary dictionaryWithObjectsAndKeys:@"categoryId",@"categoryId",@"categoryName",@"categoryName",@"categoryDescription",@"categoryDescription",@"categoryIconPath",@"categoryIconPath",@"userId",@"userId",@"categoryStatus",@"categoryStatus",@"publicPrivate",@"publicPrivate",nil] sel:@selector(finishGetDataSF:) andHandler:self]; [urlSR release]; [parser release]; } -(void)getDate:(NSDictionary*)dict { NSLog(@"Data from XML file == %@",dict); NSArray* arrayTemp = [dict copy]; }
source share