Uploaded October 2012 | Updated September 2026, 1 week ago
Subscribe to our channel here for notifications on new video trainings. For more videos on technology, visit our website at http://www.techytube.com.
By pavel@techytube, for more from this author visit:
techytube.com/author/pavel
An outlet is a property that is annotated with the symbol IBOutlet and whose value you can set graphically in a nib/xib file or a storyboard (which is new in iOS 5). You declare an outlet in the interface of a class, and you make a connection between the outlet and another object in the nib/xib file or storyboard. When the file is loaded, the connection is established.
You define an outlet as a property with the type qualifier of IBOutlet, as below:
@property (nonatomic, weak) IBOutlet UITextField *nameField;
The symbol IBOutlet is used only by Xcode, to determine when a property is an outlet, it has no actual value, and the Assistant editor gives us some nice tips about which IBOutlet property corresponds to which view on the screen when hovering on the small circle on the left of the property declaration.
Through an outlet, an object in your code can obtain a reference to an object defined in a nib file or storyboard and then loaded from that file. The object containing an outlet is often a custom controller object such as a view controller. You frequently define outlets so that you can send messages to view objects of the UIKit framework (in iOS) and the AppKit framework (in OS X).
Subscribe to our channel here for notifications on new video trainings. For more videos on technology, visit our website at http://www.techytube.com.
By pavel@techytube, for more from this author visit:
techytube.com/author/pavel
An outlet is a property that is annotated with the symbol IBOutlet and whose value you can set graphically in a nib/xib file or a storyboard (which is new in iOS 5). You declare an outlet in the interface of a class, and you make a connection between the outlet and another object in the nib/xib file or storyboard. When the file is loaded, the connection is established.
You define an outlet as a property with the type qualifier of IBOutlet, as below:
@property (nonatomic, weak) IBOutlet UITextField *nameField;
The symbol IBOutlet is used only by Xcode, to determine when a property is an outlet, it has no actual value, and the Assistant editor gives us some nice tips about which IBOutlet property corresponds to which view on the screen when hovering on the small circle on the left of the property declaration.
Through an outlet, an object in your code can obtain a reference to an object defined in a nib file or storyboard and then loaded from that file. The object containing an outlet is often a custom controller object such as a view controller. You frequently define outlets so that you can send messages to view objects of the UIKit framework (in iOS) and the AppKit framework (in OS X).
![How to use the UIImageView class to animate a series of images
Subscribe to our channel here for notifications on new video trainings. For more videos on technology, visit our website at http://www.techytube.com.
By pavel@techytube, for more from this author visit:
http://www.techytube.com/author/pavel
An image view object provides a view-based container for displaying either a single image or for animating a series of images. For animating the images, the UIImageView class provides controls to set the duration and frequency of the animation. You can also start and stop the animation freely.
You specify the animation images by setting the animationImages property of the UIImageView object:
imageView.animationImages = [NSArray arrayWithObjects:
[UIImage imageNamed:@blue],
[UIImage imageNamed:@green],
[UIImage imageNamed:@orange],
nil];
We specify the duration of the animation by setting the animationDuration property:
imageView.animationDuration = 3.0f;
We can start or stop animating the images by sending startAnimating or stopAnimating messages to the image view object:
[imageView startAnimating];
or
[imageView stopAnimating];
All images associated with a UIImageView object should use the same scale. If your application uses images with different scales, they may render incorrectly.
For more details, please visit Apples Online Documentation at:
http://developer.apple.com/library/ios/#documentation/uikit/reference/UIImageView_Class/Reference/Reference.html How to use the UIImageView class to animate a series of images](https://i.ytimg.com/vi/yEbid5QUemY/mqdefault.jpg)

![How to create view controllers programmatically in iOS
Subscribe to our channel here for notifications on new video trainings. For more videos on technology, visit our website at http://www.techytube.com.
By pavel@techytube, for more from this author visit:
http://www.techytube.com/author/pavel
The UINavigationController class implements a specialized view controller that manages the navigation of hierarchical content. This class is not intended for subclassing. Instead, you use instances of it as-is in situations where you want your applications user interface to reflect the hierarchical nature of your content. This navigation interface makes it possible to present your data efficiently and also makes it easier for the user to navigate that content.
To create a navigation controller programmatically, you have to write the following code:
UINavigationController *navController = [[UINavigationController alloc] initWithRootViewController:self.viewController];
Usually that is done in the AppDelegate.m file, but it can be done in any file you need.
If you do that in the AppDelegate.m file than you should replace the line:
self.window.rootViewController = self.viewController;
with the following line:
self.window.rootViewController = navController;
and it is perfectly ok because UINavigationController is a subclass of UIViewController.
If you run the program, you may notice a blue navigation bar appears on the top. You can customise that if you want, or you can hide it using any of the 2 lines below:
navController.navigationBarHidden = YES;
navController.navigationBar.hidden = YES;
To set a title in the NavBar, you should write in the viewDidLoad method of the ViewController class that is currently displayed by the Navigator object, any of the 2 lines below:
self.navigationItem.title = @Title;
self.title = @Title; How to create view controllers programmatically in iOS](https://i.ytimg.com/vi/zDLjdxmdwxs/mqdefault.jpg)


