I’d like to present a UIPickerView snapped to the bottom of a UITableView regardless of where it is scrolled.
Currently I have a UIPickerView added to a UITableView that I present when a button is pressed, but when I scroll the table the UIPickerView goes out of view, and if I’m scrolled out of range of where I’ve presented it, the UIPickerView appears to have never been called.
Does anyone know how to accomplish this?
Thank
Something told me that there must be a simpler alternative to the answers that I’d been given, and I found a solution.
I decided to find the y coordinate of the scroll point using
scrollViewDidScroll:and then animating the UIPickerView to the desired location.The UIPickerView will only appear if the scroll has been stopped so it’s necessary to implement a method to stop the scroll on touch:
This will allow you to display and dismiss the UIPickerView at any moment at any given destination.