Saturday, February 8, 2014
How to Get Activity Who created? (Question more vegetables)
A Mainactivity, and will call a sub-activity, and now I want to judge Mainactivity was created by laucher, or activity created from the child, to determine how to achieve?
Description:
I used inside the sub-activity is:
Intent i = new Intent (ContactAdder.this, ContactManager.class);
. . . . A. . . .
startActivity (i);
Rather than finish ();'s. Because I want to. . . A. . . Place in intnet i returned some data.
Who can give an example?
Reply:
Android callback function onActivityResult do not know if you can help
http://blog.csdn.net/ghd2000/article/details/5716894
Reply:
Thank you, Commander, I want to know the main purpose of an Activity or Activity in which the Application Intent created by up inside.
I really should not be so written examples, which should be directly finish ();'s
Reply:
(). GetAction () Try getIntent?
Reply:
Pass some data to judge the past and then get it?
Reply:
When you jump from this activity to another activity, you create an object in this activity inside the intent, then into another activity through intent implicit or explicit, that is, you say the child activity,
As I wrote in mainactivity Intent intent = new intent (this, nextactivity.class); startactivity (intent);, when triggered the intent to enter into a nextactivity that activity in the
Reply:
In an activity starts another activity one is no return value startActivity, startActivityForResult with a return value is if you want to use with the return value of Activity way to get the key from the intent focus, you can go check under startActivityForResult
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment