Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Adobe AIR Development

Posts: 167
Registered: ‎12-17-2010
My Device: Bold 9000
My Carrier: Vodafone

Clickable hyperlink in AlertDialog possible?

I want to show a clickable email address in an AlertDialog. Is that possible?

The code I have is the following, but this doesn't make the email address a clickable link.


var emailAddress:Label = new Label();
var formatter:TextFormat = new TextFormat();

with (formatter) {
	color = 0x0000FF;
	font = "Verdana";
	align = "center";
	size = 16;
	underline = true;
	url = "mailto:me@hotmail.com"; 

with (emailAddress) {
	text = "me@hotmail.com";
	format = formatter;

showDialog("About", "My App\nfor Blackberry Playbook\n\n©2011, My Name \n\n" + "Suggestions: " + emailAddress.htmlText, "Close");


And the function showDialog is defined as follows:


private function showDialog(dialogTitle:String, dialogMessage:String, dialogBtn1Txt:String = "", dialogBtn2Txt:String = ""):void {
	var dialog:AlertDialog = new AlertDialog();

	with(dialog) {
		title = dialogTitle;
		messageHtml = dialogMessage;
		dialogSize = DialogSize.SIZE_SMALL;
		if (dialogBtn1Txt != "") {
		if (dialogBtn2Txt != "") {



My PlayBook App: Checklists
Posts: 229
Registered: ‎08-14-2009
My Device: Bold 9900, DevAlpha A
My Carrier: Vodafone DE

Re: Clickable hyperlink in AlertDialog possible?

I have some HTML text in an AlertDialog as well. At the moment it looks like links do net get rendered but i reckon this will work as soon as there is a native browser on the device or the simulator.

Willy R.
If my post solved your problem, make it easier for others to find by Accepting it as a solution or provide a Kudo if it was helpful for you. Thanks.