I am new in Handling Response. While trying to fetch Values("title") in array, it is not working properly. It is updating Last Value alone in Array. How can I fetch all values("title") in an array? I even tried changing lastObject
as objectAtIndex:
Below is my Response Output and Code.
NSDictionary *book = [[ jsonResults objectForKey:@"result"] lastObject];
NSArray *title = (NSArray *) [book objectForKey:@"title"];
Response Output:
{
"result":
[
{
"authors": [
"AuthRick"
],
"bno": 9280621999,
"title": "Foo",
"urlImage": "www.foo.hoo",
},{
"authors": [
"MaveRick"
],
"bno": 9951621988,
"title": "Hoo",
"urlImage": "www.foo.hoo",
}
]
}