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

Java Development

Reply
Trusted Contributor
sakfg
Posts: 224
Registered: ‎08-09-2011
My Device: 9550
My Carrier: BBprogrammer

How to Display HTML content

[ Edited ]

Hi all,

 

 

     How to display the Html content for 4.5 Os devices(NonTouch)

 

BrowserField is there for upto 5.0 Os And Is any Other thing is there for Displaying Html content..

How to display the follow Code:

 

<html xmlns=http://www.w3.org/1999/xhtml><head><meta http-equiv=Content-Type content=text/html; charset=UTF-8 /><title>Untitled Document</title></head><body style=\"margin:0px;\">"
+ "<table width=\"850\" align=left bgcolor=#FFFFFF border=0 cellpadding=0 cellspacing=0>"
+ "<tr><td>"
+ "<table width=\"300\" align=left bgcolor=#FFFFFF border=0 cellpadding=0 cellspacing=0>"
+ "<tbody>"
+ "<tr>"
+ "<td colspan=5 bgcolor=#003478 height=10><img src=f width=25 border=0 height=10 /></td>"
+ "</tr>"
+ "<tr>"
+ "<td rowspan=4 width=10 bgcolor=#003478>&nbsp;</td>"
+ "<td colspan=3 valign=bottom width=300 align=left bgcolor=#FFFFFF height=60>SELECT FAMILY</td>"
+

"<td rowspan=4 width=10 bgcolor=#003478>&nbsp;</td>"
+ "</tr>"
+ "<tr>"
+ "<td>&nbsp;</td>"
+ "<td valign=top align=left><p><br>"

 

 

Thanks.

Please use plain text.
Developer
simon_hain
Posts: 16,010
Registered: ‎07-29-2008
My Device: Z10 LE
My Carrier: O2 Germany

Re: How to Display HTML content

easiest way is to use the browser.
you can also implement the browserfield yourself, there are some clues in other threads, but it is still a lot of work. we have an implementation, unless you really need it its not worth the hassle.
----------------------------------------------------------
feel free to press the like button on the right side to thank the user that helped you.
please mark posts as solved if you found a solution.
@SimonHain on twitter
Please use plain text.
Trusted Contributor
sakfg
Posts: 224
Registered: ‎08-09-2011
My Device: 9550
My Carrier: BBprogrammer

Re: How to Display HTML content

Thank you for reply,

 

 

      Yes ,Can you explain that implementation!!

Please use plain text.
Developer
simon_hain
Posts: 16,010
Registered: ‎07-29-2008
My Device: Z10 LE
My Carrier: O2 Germany

Re: How to Display HTML content

you implement http://www.blackberry.com/developers/docs/7.1.0api/net/rim/device/api/browser/field/RenderingApplica... implement HttpConnection to get a custom connection with the correct encoding and type, create a RenderingSession and set the needed properties on it.

Best of luck. And no, you won't get a "sample code" on that.
----------------------------------------------------------
feel free to press the like button on the right side to thank the user that helped you.
please mark posts as solved if you found a solution.
@SimonHain on twitter
Please use plain text.