swift - my slide menu button and Tabbar items not working/populating in reveal viewcontroller . why? -


i have used revealviewcontroller in take view controller , set sw_front tabbar controller , sw_rear tableview controller. when running , working fine . in tabbar controller have added 5 different view controllers , same items in tableview cells dynamically in sw_rear part. in table view each cell have connected dynamic cells related view controller based on indexpath.row . when click on tabbar items not coming . navigation items coming because before every view controller have embed navigation controller. why tabbar items not coming???

for better understanding sending few codes , screens

codes

i have set tableview each dynamic cell

switch(indexpath.row)     {     case 0 :         print("1st row")        //self.performseguewithidentifier("segueidentifier", sender: self)         let mainstoryboard = uistoryboard(name: "main", bundle: nsbundle.mainbundle())         let vc : uinavigationcontroller = mainstoryboard.instantiateviewcontrollerwithidentifier("homevc") as! uinavigationcontroller         self.presentviewcontroller(vc, animated: true, completion: nil)          case 1 :         print("2nd row")         let mainstoryboard = uistoryboard(name: "main", bundle: nsbundle.mainbundle())         let vc : uinavigationcontroller = mainstoryboard.instantiateviewcontrollerwithidentifier("menuvc") as! uinavigationcontroller         self.presentviewcontroller(vc, animated: true, completion: nil) 

but when click on ,it goes view controller tabbar items not coming

screens

enter image description here

this screen first view .here can see tabor items coming .now clicking on slide menu screen is

enter image description here

the dynamic data coming . clicking on example home screen shows enter image description here

here no tabbar items there , sliding menu button not working . doing mistake??

below code setting reveal view controller on slide menu button:

 override func viewdidload() {     super.viewdidload()      // additional setup after loading view.     if self.revealviewcontroller() != nil{         slidebtn.target = self.revealviewcontroller()         slidebtn.action = #selector(swrevealviewcontroller.revealtoggle(_:))         self.view.addgesturerecognizer(self.revealviewcontroller().pangesturerecognizer())     }   } 

you should go using performseguewithidentifier instead of instantiateviewcontrollerwithidentifier, since have custom segues. use didselectrowatindexpath method choosing segue. read this tutorial setting segues , nav/tabbar controllers properly


Comments

Popular posts from this blog

Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12:test (default-test) on project.Error occurred in starting fork -

windows - Debug iNetMgr.exe unhandle exception System.Management.Automation.CmdletInvocationException -

unity3d - Fatal error- Monodevelop-Unity failed to start -