-2

I have implemented horizontal swipe of UIViewcontrollers using UIPageViewController. It works fine as app launches, but if we navigate to any view controller by using button or any other element from any of the other viewControllers, the horizontal swipe will not work.What should I do?

Tejasvi
  • 29
  • 4

1 Answers1

0

If you are in PageViewController and present another view using a button, how are you presenting it? modally?, if so, then you are "out" of the PageViewController, and your swipes are not going to work.

If you are "jumping" to another viewController in the UIPageViewController, you will have to provide information about the previous and next page for the swipes to work, check this other post for more info: UIPageViewController, how do I correctly jump to a specific page without messing up the order specified by the data source?

Community
  • 1
  • 1
gabuh
  • 1,166
  • 8
  • 15