开发者

Want to know when UIPickerViewDataSource finished

I save the last user selection in the picker view. But when the view is opened again I do not where to use

[pickerView selectRow:lastSelectedRow inComponent:lastSelectedComponent animated:YES];

If I use it in 开发者_如何学运维viewDidLoad the problem is UIPickerViewDataSource has not finished yet, so the scrolling is not correct. I can not find delegate function after UIPickerViewDataSource is finished. Where can I use the above line of code?


You're passing YES in animated argument, thus I assume you want to see it animated -> you should call this method in viewDidAppear, not in viewDidLoad.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜