What is the best approach for navigating between "windows" in an android app?
I say "windows" because I dont the proper terminology in java. I just started.
Lets say the first screen the user sees is a username and password input with a button. On successful login, it shows a whole new "window" with relevant logged in information?
I attempted putting 2 EditTexts and a Button inside a view (using the Main.xml graphical layout tab[eclipse]) in main.xml, but it did not like that.
This is a excerpt from the page http://developer.android.com/guide/topics/fundamentals.html
Activities An activity represents a single screen with a user interface. For example, an email application might have one activity that shows a list of new emails, another activity to compose an email, and another activity for reading emails. Although the activities work together to form a cohesive user experience in the email application, each one is independent of the others. As such, a different application can start any one of these activities (if the email application allows it). For example, a camera application can start the activity in the email application that composes new mail, in order for the user to share a picture.
Here's an tutorial on how to switch between activities: http://www.warriorpoint.com/blog/2009/05/24/android-how-to-switch-between-activities/
Don't for get to add every activity to AndroidManifest.xml!
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With