0

can I use below function as an IBAction - on a button click ? if YES then please tell me how...

-(UIViewController *)pageViewController:(UIPageViewController *)pageViewController
      viewControllerAfterViewController:(UIViewController *)viewController

-(UIViewController *)pageViewController:(UIPageViewController *)pageViewController 
     viewControllerBeforeViewController:(UIViewController *)viewController
vikingosegundo
  • 52,040
  • 14
  • 137
  • 178
A K
  • 295
  • 1
  • 4
  • 19

1 Answers1

2

No, you can't.

IBAction is actually equal to void -> only void returning methods can be connected.

http://cocoadev.com/wiki/IBAction
IBOutlet and IBAction

Also the methods you are referring to are implementing the UIPageViewControllerDataSource, therefore a UIPageViewController should call them, but never you, see Delegates and Data Sources.

Community
  • 1
  • 1
vikingosegundo
  • 52,040
  • 14
  • 137
  • 178
  • so you mean that I can not call these functions programmatically ? – A K Jul 05 '12 at 12:43
  • So create a new question (after searching of course), where you ask about jumping between pages of an UIPageViewController — I never used one. – vikingosegundo Jul 05 '12 at 12:46
  • actually you did that. you should retag that, as xcode is not a valid tag for that question. It is just an IDE. you could also write apps using vi and the commandline – vikingosegundo Jul 05 '12 at 12:48