intent.action_send and intent chooser

by tnull » Tue, 20 Jul 2010 22:20:44 GMT


Sponsored Links
 When creating an intent with action send to send some data, is there a
way to filter the results that are included in the activity chooser
that is created using Intent.createChooser? I have not seen a way to
do this other than setting the mime type, but it is not flexible
enough.

For example, there is a situation when I want e-mail apps to be the
only results in the activity chooser dialog. Setting the type to "text/
html" successfully filters this down to email apps, except when
bluetooth is enabled. Bluetooth appears in the list as well, but this
is not desirable. Surely there is a way to have a little more control
over the results?

--



intent.action_send and intent chooser

by Mark Murphy » Tue, 20 Jul 2010 22:31:06 GMT


 


What are "e-mail apps"?


Only on your test environment(s). Anyone can create an application
that supports ACTION_SEND of text/html -- this it not something
exclusive to "e-mail apps". I would not be the least bit surprised if
there are others on certain devices or out on the Market.


Write your own chooser dialog, using PackageManager.

-- 
Mark Murphy (a Commons Guy)
 http://commonsware.com  |  http://github.com/commonsguy 
 http://commonsware.com/blog  |  http://twitter.com/commonsguy 

_The Busy Coder's Guide to Android Development_ Version 3.1 Available!

--


Sponsored Links


intent.action_send and intent chooser

by tnull » Tue, 20 Jul 2010 23:39:13 GMT


 With e-mail apps, I just meant I was looking to filter the results to
e-mail clients, not necessarily anything that can handle "text/html",
which I realized wouldn't work when bluetooth popped up.

Thank you for the tip on creating my own dialog using PackageManager,
I will look into that.







--



Other Threads

1. Permissions for services

Hi,

I suppose I am having permission problems with the hcid service.
I can do a start hcid, but cannot do a hcid -f /etc/hcid.conf as root. i.e I
get a Can't open HCI socket: permission denied error.
Why is that ?

Should I edit the Manifest or something for this ?

regards,
Pavan Savoy

--~--~---------~--~----~------------~-------~--~----~
unsubscribe: [EMAIL PROTECTED]
website: 

2. Low verbosity on system core

Hello,

 I'm having a problem with the init process being killed and I've
noticed that there are certain places in the source where there's not
enough verbosity on error reporting. For example, in my case, the
following code is failing in function init_property_area():

    if(init_workspace(&pa_workspace, PA_SIZE))
        return -1;

 This fails silently (for some reason that is irrelevant for this
message) and the init process crashes later. I know this may be
considered either a bug or a feature, but, in general, I consider such
things to be bugs. Am I supposed to do something about that ? If I
file a bug, is it expected to be fixed ? Am I supposed to send the
fix ? Would it be fixed. ? Another related question is: is the
expected behavior of core applications specified ? Should it be ?

--~--~---------~--~----~------------~-------~--~----~
unsubscribe: [EMAIL PROTECTED]
website: 

3. Comunication between Google MapView and LocationListener

4. open and show the database

5. Working of SensorTest

6. Hooks in Activity life cycle

7. How to rotate the emulator screen on a mac