Is it possible to push a view controller when a user selects a UIView? I have a UIView that displays an address and coordinates in it and when the user touches it, I want it to push to my map view controller where it will plot the annotation and so on… Thanks!
Share
Your address and coordinates should be inside a view (like a Label). If you setup a tap guesture on it, then the on tap, you can push the view controller.
For example, if it’s a label, here’s a relevant SO post showing handling a tap on a label: iOS using UITapGestureRecognizer with UILabel to swipe to the next page
In that example, they are scrolling to the next page, in your code, you would push the view controller.