On Fri, Sep 23, 2011 at 9:53 PM, Streets Of Boston
<[email protected]>wrote:

> 1) The onActivityResult will have a result-code of RESULT_CANCELED and its
> 'Intent data' parameter will be null.
>
> 2) Yes, you can pass back any Intent, even the one that started the
> child-activity. You don't need to create a brand new one.
>
> When an Intent is passed back or forth between Activities (starting an
> activity / setResult+finishing), the other end (getIntent() / Intent in the
> onActivityResult) doesn't get the exact same *instance *of the Intent.
> Instead, it'll get a copy of it as an Intent with the exact same contents.
> As a comparison: Intents are passed by copy, not by value or reference :-)
>

Thanks, that makes sense. However I have one more question if you don't mind
asking concerning
onRestart(), onStart() and onActivityResult(). I am using onActivityResult()
in acitivty A to store data
from acitivty B in a database. Is it safe to refresh the screen widgets with
the data in onActivityResult()
or is it better to do this inside onStart()? Plus, which gets called first,
the asynchronous onActivityResult()
or onStart(). This is what has been puzzling me lately.

Thanks for your insight,

John Goche

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to