1

I am using this code:

void openWhatsappContact(String number) {
    Uri uri = Uri.parse("smsto:" + number);
    Intent i = new Intent(Intent.ACTION_SENDTO, uri);
    i.setPackage("com.whatsapp");
    startActivity(Intent.createChooser(i, ""));
}

Except that it only opens the conversation if I have the contact in the list. Anyone know how do I get him to open the conversation even if the contact is not in the list.

Stark
  • 85
  • 1
  • 7

0 Answers0