I have this code. It is only opening WhatsApp with a particular number but not with text.
Uri uri = Uri.parse("smsto:" +mobilenumber);
Intent i = new Intent(Intent.ACTION_SENDTO, uri);
i.putExtra("sms_body", "Hello StackOverFlow");
i.putExtra("chat",true);
i.setPackage("com.whatsapp");
startActivity(i);
I have tried using Intent.EXTRA_TEXT
but no result.
How to pass the text?