Custom UIPickerView with Custom Background color

后端 未结 6 579
野的像风
野的像风 2020-12-14 11:31

I have created a sample picker-view which will display some details. Setting the Background color using:

_pickerView.backgroundColor = [UIColor redColor]; 
<         


        
6条回答
  •  庸人自扰
    2020-12-14 12:27

    UIPickerView has subviews. Assigning an image to a view and adding it to the subview at index 2, would change the background of pickerview.

    I had had a same kinda problem :-) See my question here!! Customize UIPickerView's Skin with images

    Or you can use AFPickerView

提交回复
热议问题