title: Intent does not work
body: <p>On clicking the order app in the app that i have created, it calls the submitOrder() method and it is supposed to display the order summary by calling the createOrderSummary() method in gmail .However the gmail app does not open and it displays the message (which is in the else block )that I can’t display the intent.(i am new to android development.)</p>
  
  <pre><code>CheckBox whippedCreamBox = (CheckBox) findViewById(R.id.whipped_cream_check_box);
  boolean isWhippedCreamBoxChecked = whippedCreamBox.isChecked();
  CheckBox chocolateBox = (CheckBox) findViewById(R.id.chocalate_check_box);
  boolean isChocolateBoxChecked = chocolateBox.isChecked();
  int price = calculatePrice(quantity, isWhippedCreamBoxChecked, isChocolateBoxChecked);
  EditText nameEditText = (EditText) findViewById(R.id.name_edit_text);
  Editable userEnteredString = nameEditText.getText();
  String priceMessage = createOrderSummary(userEnteredString, price, isWhippedCreamBoxChecked, isChocolateBoxChecked);
  Intent sendIntent = new Intent();
  sendIntent.setAction(Intent.ACTION_SENDTO);
  sendIntent.setData(Uri.parse("mailto:ritvikupadhyay2000@gmail.com"));
  sendIntent.setType("text/plain");
  sendIntent.putExtra(sendIntent.EXTRA_SUBJECT, "Order for the just java app");
  sendIntent.putExtra(sendIntent.EXTRA_TEXT, priceMessage);
  
  if (sendIntent.resolveActivity(getPackageManager()) != null) {
      startActivity(sendIntent);
  }
  else
  {
      displayMessage("I can't display the intent");
  }
  </code></pre>
  
  <p>and here is the java code for createOrderSummary()</p>
  
  <pre><code>private String createOrderSummary(Editable userEnteredString, int price, boolean isWhippedCreamBoxChecked, boolean isChocalateBoxChecked) {
  
  String priceMessage = "Name:" + userEnteredString + "\nAdd whipped cream?" + isWhippedCreamBoxChecked + "\nAdd chocalate?" + isChocalateBoxChecked + "\nQuantity:" + quantity + "\nTotal:$" + price + "\nThank you!\n";
  return priceMessage;
  </code></pre>