UIPickerView Width in iOS8 Swift -


i can not find out how width of component on uipickerview. it's not allowing simple (int) needs cgfloat. put in <#code#> section?

func pickerview(pickerview: uipickerview, widthforcomponent component: int) -> cgfloat {     <#code#> } 

thank you!

that method. doesn't "get width of component..." picker view calls method ask how wide component should be.

your method simple as:

func pickerview(pickerview: uipickerview, widthforcomponent component: int) -> cgfloat  {   return cgfloat(25.0) } 

(or whatever width appropriate picker view...)

you need cast result exptected type.


Comments

Popular posts from this blog

command line - Use qwinsta in PowerShell ISE -

java - Incorrect order of records in M-M relationship in hibernate -

php - I want to create a website for polls/survey like this http://www.poll-maker.com/ -