cemolcay / SlidingContainerViewController

An android scrollable tab bar style container view controller
MIT License
217 stars 41 forks source link

How to add view controllers to sliding container #7

Closed swabzz closed 8 years ago

swabzz commented 8 years ago

I have 4 uiviewcontrollers in my main storyboard. is it possible to add this for uiviewcontrollers to sliding viewcontroller

i mean i dont want to create viewcontrollers programatically.

Thanks in advance

swabzz commented 8 years ago
    //let vc1 = viewControllerWithColorAndTitle(UIColor.whiteColor(), title: "First View Controller")
  INSTED OF ABOVE LINE I AM USING

  vc1 = aViewController() [created in storyboard]

but cant see controlled of view controller it showing blank view controller

cemolcay commented 8 years ago

hi, you can instantiate view controllers in your storyboard file with UIStoryboards instantiateViewControllerWithIdentifier method. Just dont forget the give your view controller's storyboard identifier in interface builder. https://developer.apple.com/library/ios/documentation/UIKit/Reference/UIStoryboard_Class/#//apple_ref/occ/instm/UIStoryboard/instantiateViewControllerWithIdentifier: