I’m making a simple app. and it is my first app too…
It has an activity with a menu and I made each menu option in a Table Row. Each Table Row contain an Image button and a Text Description. I want to go to another Activity when we click on each Table row. How do I do that??
And is it possible to use a single class file to show multiple layout files (ie. for each menu’s content) ?
Or
Is there any other way than tableRow to create a menu like this and use it to go to another Activity?
First of all let’s see how to go to another activity by clicking on table row. In table row of your XML file property give this syntax:
Then in your Activity just after on create method put this line
By doing this when you click on table row u will be redirected to another activity name
newActivityname.Second, yes you can set different layout files for same acitivty just based on some condition. For example if we want to put layout files as per integer value condition than do like this
Like this based on some condition you can set your layout.
For your 3rd query please be more specific so that we can answer you.