I use UIPageControl
and UISwipeGestureRecognizer
to switch between the two view controllers of my application. I changed this tutorial without using scroll.
I have 2 questions:
1) Using swipe gestures changes the controllers / view pages, but not the dots indicating the current page. I tried
if (self.pageControl.currentPage == 0) { self.pageControl.currentPage = 1 }
but I'm not sure why it is not working. Output Available
@property (strong, nonatomic) IBOutlet UIPageControl *pageControl;
2) I use - (IBAction)changePage:(id)sender
to change the page. I would like to know how to go to the page when clicking on a certain point. I want to say that when I click on point 1, I have to go to the first view controller and click on point 2, I have to go to the second view controller.
source share