Hi i am getting one response from the server "{\"bindings\":[{\"Latitude\":\"25.451808633333332\",\"Longitude\":\"81.83372523333333\"}]}" , it is in array, i need to break the latitu开发者_开发知识库de and longitude part or values and initialize the value into another string.
NSString *latitudeString = [[[jsonDict objectForKey:@"bindings"]objectAtIndex:0]objectForKey:@"Latitude"];
NSString *longitudeString = [[[jsonDict objectForKey:@"bindings"]objectAtIndex:0]objectForKey:@"Longitude"];
In more nice way:
NSDictionary *gealocationDict = [[jsonDict objectForKey:@"bindings"]objectAtIndex:0];
NSString *latitudeString = [gealocationDict objectForKey:@"Latitude"];
NSString *longitudeString = [gealocationDict bjectForKey:@"Longitude"];
精彩评论