Here is How You Use the Segmented Control [UISegmentedControl]

Matthew Campbell, September 15th, 2009

A segmented control displays a list of options that a user can choose from. Each segment sort of looks like a button; the segments remains “pressed” even after the user lifts his or her finger.

You can detect when a different segment is selected and also what corresponding value in an array (that you supply) is referenced by the selected segment. Here is an example of what a UISegmentedControl looks like:

Picture-Of-A-Segmented-Control

Today I can going to show you how to use a segmented control in Objective-C code using the UISegmentedControl class. First thing is a video followed by the written instructions:

You can change the look and feel of the UISegmentedControl by altering the background color. You can use your own images and add/remove segments on the fly.

Let me know in the comments below. Be sure to link to your apps on iTunes if you have them up yet!