0

I am stuck at How do I implement such behavior of editable UITableView on XLPagerTabStrip.Requirement is quite straight forward, user can able to edit field depending upon service response. But still how do I manage editable fields of UITableview that too in paging style controller?

I am very much confused and stuck on how to achieve such thing.Should I save data in plist? Or should I use scroll view and apply constraints programmatically instead of using UITableView as a childViewController? Is there any third party library which can give me any idea about it? Any type of help and suggestion is most appreciated.

modesitt
  • 6,434
  • 2
  • 30
  • 61
Saheb Singh
  • 545
  • 4
  • 17

1 Answers1

0

The scrollview in XLPagerTabStrip is not where you are to implement your views and their behavior. It is just the container that your other view controllers are loaded into. You design your custom subclass of one of the prebuilt classes of the library, connect the appropriate views to the superclasses (like the containerView) and then you implement the method to load your view controllers inside the pager using the methods described:

override public func viewControllersForPagerTabStrip(pagerTabStripController: PagerTabStripViewController) -> [UIViewController] {
  return [MyEmbeddedViewController(), MySecondEmbeddedViewController()]
}

You design the UITableView inside presumably a UITableViewController and simply reference the this class in the delegate method above to display it.

For some more clear implimentaiton steps, you can check this answer .

Community
  • 1
  • 1
modesitt
  • 6,434
  • 2
  • 30
  • 61