1. Welcome to the new MacRumors forums. See our announcement and read our FAQ

IBOutlets not Showing Up With A Tab Bar App

Discussion in 'iPhone/iPad Programming' started by phillipie99, Jul 12, 2010.

  1. macrumors newbie

    I Created a Tab Bar App (from the template) and tried to add an IBOutlet to the viewControler.h/.m files but when I went to IB the outlets dont show up in the proxy object (Owner) or even in any object. They show up in the delegate if I declare them in the delegate.h/.m files. I,ve done everything correct for creating outlets and I know this is probably something simple. So what do I have to do to make the outlets show up in the owner object?
  2. macrumors member

    Could you post some of your code? Did you remember to do the @property & @synthesize correctly?
  3. macrumors newbie

    I started with a blank tab Bar application, so there is litle code but here is how i declared them in the viewcontroller.h file

    IBOutlet UITextFeild *test;

    @property(nonatomic, retain) UITextFeild *test;

    the .m file
    @synthisize test;

    [test dealloc];

    Im not on my mac right now so I couldnt copy the code directly but that should be exactly or almost exactly how it is in xcode.
  4. macrumors member

    UITextField not UITextFeild (probably just a typo in replying)

    @property (...) IBOutlet UITextField *test;
  5. macrumors newbie

    Yup thats just a typo and trying it with the IBOutlet in the @property statement dosent make a difference. Still no outlets.
  6. macrumors 68030


    There are some bugs in IB where it doesn't sync properly with Xcode. If you look at the lower left corner of the xib window there is a little LED icon. If the connection to the project is good then the icon is green. If it's bad then the icon is grey. Yellow also indicates a problem.

    What color is your LED?

    If grey then you may be able to fix it by checking for any spaces or other funny characters in the path to the project. Also, apparently opening the project or the xib file from the Finder may help. (I haven't seen this myself but there are lots of complaints on the Apple iPhone forum.) I do see the yellow LED.
  7. macrumors newbie

    Nope the LED is green. As i said it works if I put the connections in the delegate.h/.m files so it's working fine but not when I put the connections in the viewcontroler.h/.m maybe because it is a tabbar app with a tab bar controler not a normal view controler?
  8. macrumors 68030


    Did you set the Class of the File's owner?

    Do you want to show a screenshot of where you expect the outlets to be?
  9. macrumors newbie

    Ill post a couple of screenshots up at about 8:30-9:00 (eastern standard time)
  10. macrumors newbie

    After trying with a few different types of software and the built in screen shot mecanism I was unable to take a screen shot. I here the photo sound but nothing apears on my desktop not matter what I try. Ill keep trying.
  11. macrumors newbie

    screen shot can be achieved by SHIFT + COMMAND + 3 in Mac.

    PhoneyDeveloper provided a very good point : What is the class of your File's owner. (It should be specified as your class definition not UIViewController)

    Thanks! PhoneyDeveloper...

Share This Page