Hello, I hope you will read this question, because this problem is
driving me crazy:
It's about the Gallery application. I've registered my application as
a target for the "Share" option where the selected picture is being
sent to another Activity in order to share it. The default application
in the emulator was Messaging, and the image is attached using this
option. Well, now I've got my application and Android asks me which
application should it use to complete the action. I select my
application and it opens the correct Activity, but... how can I get
the image?
My code (that doesn't work) is as follows:
Intent i=getIntent();
Bundle extras=i.getExtras();
Uri uri = (Uri) extras.getParcelable(Intent.EXTRA_STREAM);
AddImageFromUri(uri);
While debugging, the intent and the bundle .toString() methods give
the following results:
i -> Intent { action=android.intent.action.CHOOSER flags=0x3800000
comp={com.superjmn.app.onblog/com.superjmn.blog.EditEntryActivity}
(has extras) }
extras -> Bundle[mParcelledData.dataSize=636]
But with this, uri is null. I've tried myriads of combinations, but
none works.
Please, help me. Thanks a lot!
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---