I have a scroll view which contains different ui components such as text fields, labels etc. The scroll view takes almost the full size of the screen. Logically separated, I want to add/display a button which is not a part of the content of the scroll view.
This leads to the problem that my button doesn't react on my touches. In case, I reduce the size of the scroll view so that the frames don't interfere with the ones from the button, everything works as expected.
I tried to bring the button to the front (view.bringSubviewToFront(infoButton)) but it still doesn't work.
I think you want to implement something like 'Gmail app, a plus button is floating at the bottom right of the screen. add your scroll view to view and add other elements to scroll view:
after you finished adding scrollView's sub views it's time to add your button to -> View (not scroll view) and everything should work fine as you expected