title: How to forward sms to selected contacts to whatsapp from my Android app?
body: <p>Here i am stuck from few days, i am trying to send sms(that predefined set from my app ) with selected contact to whats app, with the help of stackoverflow i found two method to send sms to <code>whatsapp</code>.</p>
  
  <p><strong>1st method:</strong> one method is forward sms to <code>whatsapp</code> well, but not with selected contact, contact can be select from <code>whatsapp</code> but i not want that. I want contact also should be select from my app.now</p>
  
  <p><strong>2nd method:</strong> second method is opposite to first. This method send selected contact to <code>whatsapp</code> for sms but not with (predefined sms).
  My problem is that i want both things should be passed to <code>whatsapp</code> from my app sms+Contact.When i try merge both method gives error. Please Help me 
  here is my code for 1st method and 2nd method.</p>
  
  <pre><code>    //1st method: for forward sms to whatsapp
          Intent waIntent = new Intent(Intent.ACTION_SEND);
          waIntent.setType("text/plain");
          String text = "YOUR TEXT HERE";
          waIntent.setPackage("com.whatsapp");
          waIntent.putExtra(Intent.EXTRA_TEXT, text);
          startActivity(waIntent);
  
  
      //2nd method: send sms with selected contact but not with predefined sms 
         void openWhatsappContact(String number) {
         Uri uri = Uri.parse("smsto:" + number);
         Intent i = new Intent(Intent.ACTION_SENDTO, uri);
         i.setPackage("com.whatsapp");
         startActivity(i);
  
  
    //here i am trying to send both SMS and contact from my Android app but not working and get error. 
          Uri uri = Uri.parse("smsto:" + "065214585756");
          Intent sendIntent = new Intent(Intent.ACTION_SENDTO, uri);
          sendIntent.putExtra(Intent.EXTRA_TEXT, "Hai Good Morning");
          sendIntent.putExtra("chat",true);
          sendIntent.setType("text/plain");
          sendIntent.setPackage("com.whatsapp");
          startActivity(sendIntent);
  </code></pre>
  
  <p>Please any one help me.How i can do it.</p>