javaandroidhtmlcssfromhtml

Html.fromHtml not working with bold text in body while share intent in email


String mailContent = "<b>boldText:</b>"

I tried below also but not working.

String mailContent = "<strong>boldText:</strong>"

Email intent.

Intent sendIntent = new Intent(Intent.ACTION_SEND);
sendIntent.setType("text/html");
sendIntent.putExtra(Intent.EXTRA_SUBJECT, 
getResources().getString(R.string.slide3_text1));
sendIntent.putExtra(Intent.EXTRA_TEXT, Html.fromHtml(mailContent));
startActivity(Intent.createChooser(sendIntent, "Send Mail"));

Please check this code not showing bold text in mail. i want to display like below.

Title of Content:

Name

etc...

Title of Content 2:

Name

etc.

Please take look into this and let me know I read many blogs. Thanks in advance.


Solution

  • As per R&D, I found that this is not possible in new Gmail because Gmail introduces own editor in the mail. Thanks