I want to make a part of message text in Bold in AlertDialog.
I tried:
adding <b> </b> tag
in strings.xml
but nothing positive.
i have also used Html.fromHtml("<b>"+getString(R.string.ittformulanote)+"</b>")
i have also been to stackoverflow.com but no positive result.
Below my Code:
showDialog(getActivity(),"Sample",Html.fromHtml("<b>"+getString(R.string.ittformulanote)+"</b>")+"\n\n"+));
public static void showDialog(Context mContext, String Title,
String Description) {
final AlertDialog.Builder dialog = new AlertDialog.Builder(mContext);
dialog.setTitle(Title);
// dialog.setMessage((Html.fromHtml("<b>"+Description+"</b>")));
dialog.setMessage(Description);
dialog.setPositiveButton("OK", new DialogInterface.OnClickListener() {
@Override
public void onClick(DialogInterface dialog, int which) {
dialog.dismiss();
// TODO Auto-generated method stub
}
});
//
AlertDialog alert=dialog.create();
// dialog.show();
alert.show();
}