xamarin.ios - iPhone UIPickerViewModel Multiple components -
I have set a picker model for a customer class, which gets the UIPR ViewModel
I display the data of the first component to the picker (it has 2) but I do not see any way to tell the picker that value is for the second column?
I am using MontoTouch.net, but the obj-C answer is OK.
Override GetRowsInComponent (UIPickerView picker view, integer component)
This does not allow me to specify the data for two columns, such as when I use the data source and Use representative.
You have to override the GetComponentCount method and in that case 2 should return. You want something like this:
Public override int GateCommentCount (UIPickerView picker view) {return2; } Public override int GetRowsInComponent (UIPickerView pickerView, int component) {// component will be 0 or 1: return value [component]. Lamps; }
Comments
Post a Comment