NSCry
NSCry

Reputation: 1652

Customize Picker View in iPhone

How to create Customized UIPicker View in iphone.I want to customize the background Color,Style of wheel.I also want to customize the different row's selection.How it will be done. Can Anyone help me Thanks in advance.

Upvotes: 0

Views: 1048

Answers (2)

Desdenova
Desdenova

Reputation: 5377

You change change the view of the rows as Gypsa stated.

However if you want to change the appearance of the UIPickerView, laying out a transparent png on top of it is your best bet. Just make sure you disable user interactions on the png, so that you can interact with the wheel.

Below screenshots are from my latest app.

Good luck.

Nib without the skin:

Nib without the skin

Nib with the skin:

Nib with the skin

Final app:

Final app

Upvotes: 1

Gypsa
Gypsa

Reputation: 11314

Hi Use this method to customize your pickerview:-

- (UIView *)pickerView:(UIPickerView *)pickerView viewForRow:(NSInteger)row forComponent:(NSInteger)component reusingView:(UIView *)view
{
}

This is the delegate method which is called when picker view loaded or reloads

Upvotes: 1

Related Questions