Display images in TabBar Application in iPad

This is the very easy example . We will see how to image display in the different tab in the TabBarApplication using only Interface Builder.

This is the very easy example . We will see how to  image display in the different tab in the TabBarApplication using only Interface Builder.

Step 1: Create a TabBar Application using template. Give the application name “TabBarApplication_iPad”.

Step 2: Xcode automatically creates the directory structure and adds essential frameworks to it. You can explore the directory structure to check out the content of the directory.

Step 3: Xpand classes and notice Interface Builder created the TabBarApplication_iPadViewController class for you. Expand Resources and notice the template generated a separate nib,TabBarApplication_iPadViewController.xib, for the “TabBarApplication_iPad”.

Step 4: We need to add two images in the Resource folder. Give the images name “1.png”, “2.png”.

Step 5: Double click the FirstView.xib file and open it to the Interface Builder. First drag the UIImageView from the library and place it to the View window. Select the UIImageView from the view and bring up Attribute Inspector and select the “1.png”. Connect File’s Owner icon to the View icon and select the view. Save the .xib file and go back to the Xcode.

Step 6: Double click the SecondView.xib file and open it to the Interface Builder. First drag the UIImageView from the library and place it to the View window. Select the UIImageView from the view and bring up Attribute Inspector and select the “2.png”. Connect File’s Owner icon to the View icon and select the view. Save the .xib file and go back to the Xcode.

Step 7: Now compile and run the application in the Simulator.

You can Download SourceCode from here TabBarApplication_iPad

WP Greet Box icon
Hello there! If you are new here, you might want to subscribe to the RSS feed for updates on this topic, and free programming tips and tricks and source code            snippets.

Leave a Reply

Security Code:

learn iphone programming

Looking for something?

Use the form below to search the site:

Still not finding what you're looking for? Drop a comment on a post or contact us so we can take care of it!

Our Mobile Training Courses

EDUmobile.ORG offers the following 4 Mobile Training Courses. Our iPhone Training Course is very popular, with over 200 developers in training.

learn iphone programming
© 2010 EDUmobile.ORG