Instance Method

pickerView:accessibilityLabelForComponent:

Returns a string that identifies the picker view component.

Declaration

- (NSString *)pickerView:(UIPickerView *)pickerView accessibilityLabelForComponent:(NSInteger)component;

Parameters

pickerView

The picker view object.

component

The component in the picker view that requires a label.

Return Value

A succinct label, in a localized string, that identifies the picker view component.

Discussion

Implement this optional method to ensure that the accessibility element representing the picker view provides an appropriate label for each component. The system prefers the pickerView:accessibilityAttributedLabelForComponent: method over this one. For in-depth information on how to create an appropriate label, see Crafting Useful Labels and Hints.

See Also

Providing Descriptive Information

- pickerView:accessibilityAttributedLabelForComponent:

Returns an attributed string that identifies the picker view component.

- pickerView:accessibilityHintForComponent:

Returns a string that describes the result of performing an action on the component.

- pickerView:accessibilityAttributedHintForComponent:

Returns an attributed string that describes the result of performing an action on the specified component.