Welcome!

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


Thank you for visiting the BlackBerry Support Community Forums.

BlackBerry will be closing the BlackBerry Support Community Forums Device Forums on April 1st (Developers, see below)

BlackBerry remains committed to providing excellent customer support to our customers. We are delighted to direct you to the CrackBerry Forums, a well-established and thorough support channel, for continued BlackBerry support. Please visit http://forums.crackberry.com or http://crackberry.com/ask. You can also continue to visit BlackBerry Support or the BlackBerry Knowledge Base for official support options available for your BlackBerry Smartphone.

"When we launched CrackBerry.com 10 years ago, we set out to make it a fun and useful destination where BlackBerry Smartphone owners could share their excitement and learn to unleash the full potential of their BlackBerry. A decade later, the CrackBerry community is as active and passionate as ever and I know our knowledgeable members and volunteers will be excited to welcome and assist more BlackBerry owners with their questions."

- Kevin Michaluk, Founder, CrackBerry.com

Developers, for more information about the BlackBerry Developer Community please review Join the Conversation on the BlackBerry Developer Community Forums found on Inside BlackBerry.


Reply
Contributor
Posts: 33
Registered: ‎01-15-2011
My Device: Not Specified

Re: Hyperlink in AlertDialog

Really?!

 

I have an event handler for the button. When it's clicked, this is what is run:

 

 

var file : File = File.applicationDirectory.resolvePath( "info.html" );
			if(file.exists)
				trace("exists");
			navigateToURL( new URLRequest("file://" + file.nativePath ));

 

 

It tells me that the the file does indeed exist. But when the button is clicked, the browser doesn't open up...nothing happens! I cannot figure this out for the life of me!!

Developer
Posts: 6,541
Registered: ‎10-27-2010
My Device: HTC One, PlayBook, LE Z10, DE Q10
My Carrier: Verizon

Re: Hyperlink in AlertDialog

For testing purposes, try:

var file : File = File.applicationDirectory.resolvePath( "info.html" );
if(file.exists)
trace("exists");
navigateToURL( new URLRequest("http://www.google.com"), "_blank" );

 

Dont forget about the window id (_blank).

Contributor
Posts: 33
Registered: ‎01-15-2011
My Device: Not Specified

Re: Hyperlink in AlertDialog

 

var file : File = File.applicationDirectory.resolvePath( 'info.html' );
			if(file.exists)
				trace("exists");
			navigateToURL( new URLRequest('http://www.google.com' ));

 

works like a charm, with and without "_blank". However, as soon as I put the file in there...nothing happens...

 

Developer
Posts: 6,541
Registered: ‎10-27-2010
My Device: HTC One, PlayBook, LE Z10, DE Q10
My Carrier: Verizon

Re: Hyperlink in AlertDialog

Wish I had something I could test on the simulator.  Try:

 

"file://./info.html"
"file://app/index.html"
"./info.html"
"app/info.html"

 

 

If this does not work, then either it is a bug or someone wiser (and sample app in the simulator), can figure this one out.  It is probably "Oh, **beep***.  Yeah that makes sense".  But after 14 hours of coding, my brain is cooked.

Contributor
Posts: 33
Registered: ‎01-15-2011
My Device: Not Specified

Re: Hyperlink in AlertDialog

No luck Smiley Sad