How can I get whats been selected in a segmented control?
+2
A:
Use selectedSegmentIndex
.
EDIT:
To retrieve the title of the segment, pass this NSInteger
into titleForSegmentAtIndex:
. Please note that if selectedSegmentIndex
does not return a positive value, using it for titleForSegmentAtIndex
will cause an error.
jrtc27
2010-07-12 12:12:06
sweet thanks!!!
2010-07-12 12:41:58