I have a UIPicker View with 2 components. The title for the rows of each component are in relationship, that is, the texts and number of the rows in the 2nd component will change according to the selected row in the 1st component.
Now, the problem is, when I scroll the two components together, my app crashes.
I guess the reason is that when the 1st component is being scrolled, the supposed number of rows in 2nd component keeps changing, but meantime, the UIPickerView is asking for the title and number for the 2nd component, then it crashes.
But I haven't found any method that can be used to judge whether a component is being scrolled. So I can't find the correct time to reject the request of the pickerView's delegate and datasource for the 2nd component.
What am I supposed to do?