1 message in com.googlegroups.android-developersRe: [android-developers] OnActivityRe...| From | Sent On | Attachments |
|---|---|---|
| Megha Joshi | 30 Jan 2008 17:07 |
| Subject: | Re: [android-developers] OnActivityResults via several Activities![]() |
|---|---|
| From: | Megha Joshi (mjo...@google.com) |
| Date: | 01/30/2008 05:07:10 PM |
| List: | com.googlegroups.android-developers |
Hi Markus,
Your question has been answered at the link below: http://groups.google.com/group/android-beginners/browse_thread/thread/ce57093c0afcd36d
Thanks, Megha
On Jan 29, 2008 5:12 AM, Markus <mark...@email.de> wrote:
Sorry for doublepost this message, but i think this group is more appropriate the the group of the original post Hi there, I've got following problem: I've got 3 activities which represents some kind of wizzard. The first activity starts the second via startSubActivity. In the same way the second activity starts the third. On the 3rd activity there is a button called "Finish". If the button is pressed the programm is running following code in the listener:
setResult(RESULT_OK); finish();
In the second activity I'm catching it with the OnActivityResult- Method in that way: protected void onActivityResult(int requestCode, int resultCode, String data, Bundle extras) { switch(resultCode) { case RESULT_OK: setResult(resultCode); finish(); break; case RESULT_CANCELED: setResult(resultCode); finish(); break; } //super.onActivityResult(requestCode, resultCode, data, extras); }
In the first activity I've implemented also an onActivityResult but it seems that the code never reachs there. The first activity is displayed but my breakpoint in the onActivityResult is never hit.
What have I done wrong? Any hints?
Thanks
Markus




