ask123
ask123

Reputation: 217

Tab bar is also moving when i scroll the table view

I have written the code programmatically for my tab bar in my table view.The problem whenever i am scrolling the table view,the tab bar is also moving.The tab bar created in one cell,so it is also scrolling.How to keep that in static.Please help me in this. Thanks in advance

Upvotes: 0

Views: 532

Answers (2)

John Parker
John Parker

Reputation: 54445

If you're creating the tab bar as one of the cells, this will always happen. (It's the expected behaviour for the table cell.)

Why on earth are you using this approach, rather than simply putting the tab bar above or below the UITableView?

Upvotes: 0

PengOne
PengOne

Reputation: 48398

DOn't put the TabBar in the Scrollview. Rather, have the TabBar at the bottom of the main view, and have the ScrollView extend only to the top of the TabBar. That should fix it. If you put the TabBar on the ScrollView, it will scroll around (that's what the ScrollView does).

Upvotes: 1

Related Questions