You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If I use delegate method as above, I am getting both warning and error as shown in below image:
Changing method to following remvoes the warning but error is still there: @objc func czpickerView(pickerView: CZPickerView!, didConfirmWithItemsAtRows rows: Array) { }
What I'm missing for this method?
The text was updated successfully, but these errors were encountered:
@Astuter if you integrate CZPicker using cocoapods in a Swift project, you can click into the CZPickerViewDelegate header file, where the content is as follows:
publicprotocolCZPickerViewDelegate:NSObjectProtocol{/** delegate method for picking one item */optionalpublicfunc czpickerView(pickerView:CZPickerView!, didConfirmWithItemAtRow row:Int)/* delegate method for picking multiple items, implement this method if allowMultipleSelection is YES, rows is an array of NSNumbers */optionalpublicfunc czpickerView(pickerView:CZPickerView!, didConfirmWithItemsAtRows rows:[AnyObject]!)/** delegate method for canceling */optionalpublicfunc czpickerViewDidClickCancelButton(pickerView:CZPickerView!)}
Therefore, you should use [AnyObject]! instead of Array. I just created a swift demo, you can refer to that project.
I want to let use select multiple item in my PickerView.
func czpickerView(pickerView: CZPickerView!, didConfirmWithItemsAtRows rows: Array!) { }
If I use delegate method as above, I am getting both warning and error as shown in below image:
Changing method to following remvoes the warning but error is still there:
@objc func czpickerView(pickerView: CZPickerView!, didConfirmWithItemsAtRows rows: Array) { }
What I'm missing for this method?
The text was updated successfully, but these errors were encountered: