BlackBerry Forums Support Community
              

Closed Thread
 
LinkBack Thread Tools
Old 02-22-2009, 08:21 PM   #1 (permalink)
New Member
 
Join Date: Feb 2009
Model: 8320
PIN: N/A
Carrier: china mobile
Posts: 9
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default How to implement a link field

Please Login to Remove!

In the blackberry browser , you open a web page,when you navigation a hyperlink element, you can click the link to open a new page, or open the browser menu ,click the Get Link menu to open the page. now I want implement a custome Field just like this.

I can extends net.rim.device.api.ui.Field to implement a LinkField, or there is any chance to use the field that the browser used. In the api docs I can not find how the browser render the html url link.

any suggestion. thanks!
Offline  
Old 02-22-2009, 08:51 PM   #2 (permalink)
New Member
 
Join Date: Feb 2009
Model: 8320
PIN: N/A
Carrier: china mobile
Posts: 9
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default

I searched the forum. and found a post:
www .blackberryforums .com/developer-forum/172635-how-do-i-include-web-link.html
It seems can use ActiveRichTextField , when the text match the certen StringPattern.



add(new RichTextField("A phone number to call in the U.S.",Field.NON_FOCUSABLE));
add(new ActiveRichTextField("1-800-555-1212",Field.FOCUSABLE));
add(new RichTextField("An Email Address to use.",Field.NON_FOCUSABLE));
add(new ActiveRichTextField("support@rim.com",Field.FOCUSA BLE));


use

add(new ActiveRichTextField("www .google .com",Field.FOCUSABLE));

to get the url page. but I want the rendering text is Google not the www .google .com , so how to do that.

I remove the http protocol text because the post limit: To be able to post links or images your post count must be 10 or greater.
Offline  
Closed Thread


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

20x BD140 TO-126 Silicon PNP Transistor 80V 1.5A SOT-32 US SELLER 20pcs Y34
$5.99
20x BD140 TO-126 Silicon PNP Transistor 80V 1.5A SOT-32 US SELLER 20pcs Y34 picture15 USED TOSHIBA 1N249B 100 v 20 a DIODE RECTIFIER ECG 5982
$10.0
15 USED TOSHIBA 1N249B 100 v 20 a DIODE RECTIFIER ECG 5982  pictureKeyence KV-16AT PLC Base Unit, AC Type, 10 Inputs and 6 Transistor (Sink) Output
$88.95
Keyence KV-16AT PLC Base Unit, AC Type, 10 Inputs and 6 Transistor (Sink) Output pictureLCR-T4 ESR Meter Transistor Tester Diode Triode Capacitance SCR Inductance UE
$10.65
LCR-T4 ESR Meter Transistor Tester Diode Triode Capacitance SCR Inductance UE pictureECG182 NPN POWER TRANSISTOR TO-127 REPL NTE182
$3.99
ECG182 NPN POWER TRANSISTOR TO-127 REPL NTE182 picture






Copyright 2004-2016 BlackBerryForums.com.
The names RIM and BlackBerry are registered Trademarks of BlackBerry Inc.