Navigation controller app newbie help

Discussion in 'iOS Programming' started by troop231, Feb 14, 2011.

  1. troop231, Feb 14, 2011
    Last edited: Feb 14, 2011

    troop231 macrumors 603

    Jan 20, 2010
    Trying to work on my app and I'm really stumped on how to accomplish loading a pdf view in the next drill down when I click on a state. For now, I have the detailView set to display a message saying: You have clicked on (x)state, but I want to use a UIWebView to load a local resource pdf file for the selected state.

    So basically so far I have: A first level view controller, a second level view controller, and a detail controller. I have an array of states init'ed in the void viewDidLoad but not really sure how to point each row in the list to the associated pdf file for that state, here's some pics: THANKS! :D

  2. ianray macrumors 6502

    Jun 22, 2010
    So you have a UITableView? This method is called when a row is selected, and you will need to instantiate a UIViewController sub-class (that has a UIWebView) in order to present the PDF.

    - (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
  3. troop231 thread starter macrumors 603

    Jan 20, 2010
    Huh? I'm pretty sure I already have that, but I'm wondering if I should make an array in a plist with all the states and the values of the pdfs but I'm not sure how to do that.

Share This Page