I had developed an application for sending email. On click of email button it should ask user to choose one of email clients installed in phone. But, in my case additionally it is showing option of bluetooth which is not required. I searched alot but couldn't got any solution. Below I am posting my code.
public class EtestActivity extends Activity {
/** Called when the activity is first created. */
Button email;
Intent in;
private static final String TAG = "EmailLauncherActivity";
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.main);
email = (Button)findViewById(R.id.email);
email.setOnClickListener(new View.OnClickListener() {
public void onClick(View v) {
// TODO Auto-generated method stub
try {
in = new Intent(Intent.ACTION_SEND);
in.setType("image/jpg");
in.setType("plain/text");
in.setType("application/octet-stream");
in.putExtra(Intent.EXTRA_EMAIL, new String[]{"pranav_kotauniv@yahoo.co.in","friendlynitish@gmail.com"});
in.putExtra(Intent.EXTRA_STREAM, Uri.parse("file:///sdcard/android.jpg"));
startActivity(Intent.createChooser(in, "mailto:"));
} catch (Exception e) {
Log.e(TAG, "email sending failed", e);
}//catch
}//onClick
});
}//onCreate
}//class