i have a NSArray with a lot of Data coming from JSON.
This is from my JSON Database
{
"ID":"6173",
"Name":"Heuriger Familie Haller",
"BeschreibungApp":"Heuriger Familie Haller, 2102 Bisamberg",
"Link":"http:\/\/heurigenapp.nocache.gugler.at\/app.php?id=6173",
"Icon":"Weintraube",
"Latitude":"48.33284",
"Longitude":"16.36383",
"Altitude":"0",
"Ort":"Bisamberg"
}
I have 20 objects like this. And all this i have in a NSArray.
But i want an Array only with “Ort” so i don’t need most of the information.
can i do it like this:
newsTown = [news valueForKey:@"Ort"];
sure, KVC to the rescue 😀
you want to follow a KeyPath:
Array *new = [array valueForKeyPath:@"Ort"];ASSUMING news is your NSArray of the JSON dics