Can't change title that appears at top of opening page

Discussion in 'iOS Programming' started by StevenHu, Dec 15, 2009.

  1. StevenHu macrumors member

    Joined:
    Sep 3, 2009
    Location:
    Southern CA
    #1
    I used Apple's UICatalog to jump-start my app. Now I find I can't get rid of the "UICatalog" title that appears on the first page, a UITableView. It appears in the blue band at top. How do I change it? I can't find out where it's set.

    Thanks!
    Steve H
     
  2. csnplt macrumors 6502

    csnplt

    Joined:
    Aug 29, 2008
    Location:
    Chicago Area
    #2
    In any view controller, you can change the title like this:

    myViewController.title = @"My title";

    If you have a navigation bar at the top, as you do, it will display your title.
     
  3. KoolStar macrumors demi-god

    KoolStar

    Joined:
    Oct 16, 2006
    Location:
    Kentucky
    #3
    If you open the mainview.xib, then select the navigation controller. Then open the root view you can change the title in IB as well as using self.title = @"Title";
     
  4. StevenHu thread starter macrumors member

    Joined:
    Sep 3, 2009
    Location:
    Southern CA
    #4
    Thank you for the "title" line. That successfully overwrote the original title.

    When I double-click on the MainView.xib, it doesn't open in IB. I notice that's true of several other Apple sample code xib files. Why won't they open in IB?

    Thanks!
     
  5. PhoneyDeveloper macrumors 68030

    PhoneyDeveloper

    Joined:
    Sep 2, 2008
    #5
    This is a very long standing bug in Xcode. Xcode doesn't properly support localization. All of the iPhone examples use the en.lproj folder name for localization. Xcode supports English.lproj.

    To make the nib file open from Xcode you need to turn the disclosure triangle next to its name. Then double click on the name 'en' that shows in the file list. If a nib file is inside English.lproj then you don't need to open the disclosure triangle to open the file.
     
  6. StevenHu thread starter macrumors member

    Joined:
    Sep 3, 2009
    Location:
    Southern CA
    #6
    Thanks! Clicking on the en file opened it up.

    Regards,
    Steve H
     

Share This Page