,你可以用其他方式,你可以使用字符串基本的HTML如實例
<string name="send_mail"><![CDATA[ <a href="mailto:[email protected]">email us</a>]]></string>
而且如例如
AlertDialog.Builder builder = new AlertDialog.Builder(this);
builder.setTitle("Data")
.setIcon(R.drawable.info)
.setMessage(Html.fromHtml(R.string.send_mail)
.setCancelable(true)
.setNegativeButton("OK",null);
AlertDialog welcomeAlert = builder.create();
welcomeAlert.show();
// Make the textview clickable. Must be called after show()
((TextView)welcomeAlert.findViewById(android.R.id.message)).setMovementMethod(LinkMovementMethod.getInstance());
有關更多詳細信息創建AlertDialog,請看看這個問題Link
讓我試試這個。這可能正是我需要的。謝謝! – portfoliobuilder 2014-11-14 21:39:05