我在电子邮件意图中使用标记<table>
html显示表格有问题,这是我的代码:
String[] TO = {""};
String[] CC = {""};
String msg= "<table border=1>" +
"<th>WO</th>" +
"<th>Item Number</th>" +
"<th>Qty Open</th>" +
"<th>UOM</th>" +
"<th>Due Date</th>" +
"<tr>" +
"<td>WO0001</td>" +
"<td>FG001</td>" +
"<td>100</td>" +
"<td>EA</td>" +
"<td>15-03-2016</td>" +
"</tr>" +
"<tr>" +
"<td>WO0002</td>" +
"<td>FG002</td>" +
"<td>150</td>" +
"<td>EA</td>" +
"<td>25-03-2016</td>" +
"</tr>" +
"<tr>" +
"<td>WO0005</td>" +
"<td>FG002</td>" +
"<td>100</td>" +
"<td>EA</td>" +
"<td>13-04-2016</td>" +
"</tr>" +
"</table>";
Intent emailIntent = new Intent(Intent.ACTION_SEND);
emailIntent.setData(Uri.parse("mailto:"));
emailIntent.setType("text/html");
emailIntent.putExtra(Intent.EXTRA_EMAIL, TO);
emailIntent.putExtra(Intent.EXTRA_CC, CC);
emailIntent.putExtra(Intent.EXTRA_SUBJECT, mType);
emailIntent.putExtra(Intent.EXTRA_TEXT, Html.fromHtml(msg));
表格无法显示,我知道Html.fromHtml不支持标记<table>
。是否有任何解决方案在Android电子邮件意图中使用<table>
html?谢谢