I want to share my application via Facebook, Twitter, email, and messaging. I do not want to share it with the other options that are presented when using the share button.
I am currently using the following code for the share button:
sharebuton.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
// TODO Auto-generated method stub
String TEXT = "I shared the file " + " via MyApp";
Intent sendIntent = new Intent(Intent.ACTION_SEND);
sendIntent.setType("text/plain");
sendIntent.putExtra(Intent.EXTRA_TEXT, TEXT);
startActivity(Intent.createChooser(sendIntent, "Share the program:"));
}
});
When using this code the user is presented with other options to share the application like Gmail, Notepad, Peep, Bluetooth, etc. as well as the four options mentioned above.
Is it possible to filter the share options so that only the four options (Facebook, Twitter, email, and messaging) are presented to the user?