JSON Parsing and put in TableView+Hierarchy

Discussion in 'iOS Programming' started by mehdies, Nov 10, 2013.

  1. mehdies macrumors member

    Jun 10, 2012
    Hi Friends,

    I have 3 ViewController : 1 - ViewController.h/.m/.xib
    2 - FirstViewController.h/.m/.xib
    3 - ShowContentViewController.h/.m/.xib

    My first and second ViewController's have TableView(each one has a TableView) for showing Name element of first JSON file (category.json) and ShowContentViewController have a UIImageView to show an image.

    First JSON file have like this :

    and second JSON file have like this :

    i want to program work like following :

    1 - when program starts : first ViewController show name's with parented = 0 in cells
    2 - when user select any on Name's,program show second ViewController with correspond item in JSON.for example if user Select Norway(id=1) program show Oslo(parentid=1).
    3 - if user select any of items in second ViewController program show correspond image from second JSON file.for example if user first select Norway and the select Oslo(id=100) we must see oslo.jpg(pid=100)

    * these are sample JSON file and maybe when user select any parentid=0 item program show more items than one.
    * i can show item's with parentid=0 but after that i can't continue!

    Could you explain me roadmap??

  2. Tander macrumors 6502a


    Oct 21, 2011
    Johannesburg, South Africa
    What have you tried to do so far?
    Do you have any code yet or have you not even attempted this yet?
  3. IDMah macrumors 6502


    May 13, 2011
    I used this Tutorial as a framework. And .. JSON Parse Tutorial

    I find Ray's stuff awesome also has a few UITableView tutorials.

    Both were extremely useful to a 'nube' like me.
    Good Luck good code.

Share This Page