In my application, I see several actions ...
Main | -------------------- Login | | | --------------- Dashboard | ----------------------------------------- | | | Activity1 Activity2 Activity3
If the user is logged in, he bypasses the login and goes directly to the dashboard. Then I see a toolbar that launches other actions. Currently, my main vision is as follows:
public class MainActivity extends Activity { User user = null; @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); startActivity(new Intent(this, LoginActivity.class)); } }
I tried to find a code example showing how to transfer data from my login activity to Main, but I struggled. I can find many examples of how to transfer data from parent activity to child activity, but not vice versa.
PS - If I am not on the right track with my application, please let me know!
source share