ios - Swift 3 tab bar disable tab -


i have created tab bar 5 tabs. want create feature can enable / disable tabs of tab bar programmatically user not able click on it.

we have used default tab bar controller , using swift 3. has idea how manage stuff?

i have tried many ways seems not possible restrict user click on tab.

please let me know if has faced , solved issue.

let tabbarcontrolleritems = self.tabbarcontroller?.tabbar.items  if let tabarray = tabbarcontrolleritems {     tabbaritem1 = tabarray[0]     tabbaritem2 = tabarray[1]      tabbaritem1.isenabled = false     tabbaritem2.isenabled = false     } 

just put block of code above in viewdidload() method starters , don't forget create tabbaritem variables


Comments

Popular posts from this blog

node.js - Node js - Trying to send POST request, but it is not loading javascript content -

javascript - Replicate keyboard event with html button -

javascript - Web audio api 5.1 surround example not working in firefox -