Reputation: 1
I'm writing my first android app and having some trouble. I have 4 layouts, each with their own xml file and the same 4 buttons at the top of each screen. The 4 buttons should simply switch between the 4 layouts, but I can't get it to work. When the app laucnhes, I can click on any 1 button and it works, but I can't click on another one after that to change the layout again. The buttons are defined in each xml and I'm thinking that is the problem. Is there a better way to do this? Something similar to frames in html?
Upvotes: 0
Views: 875
Reputation: 76466
Hey you'll be wanting a Tab Layout right?
http://developer.android.com/resources/tutorials/views/hello-tabwidget.html
http://www.techwavedev.com/?p=14
Upvotes: 5