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
Developer
Posts: 76
Registered: ‎03-15-2010
My Device: 9800, 9630
My Carrier: Rogers

Browser Field2 HTML Source?

Hello,

 

I'm trying to figure out a way to pull the raw HTML source code from a rendered browser.field2 field. I've been searching through the Document and Element objects of the loaded page with no success. All I have been able to get is a text formatted version of the page with all tags removed. Searching for an answer has not resulted in any help.

 

Am I missing something here? Is there a way to do this?

 

Thanks,

Jason

 

Developer
Posts: 53
Registered: ‎10-29-2010
My Device: Not Specified

Re: Browser Field2 HTML Source?

The only way is that you download all the content (and manage any redirection using the response code).

 

So, instead of passing to the BrowserField2 an HTTPConnection you'll pass a String with the content and the URL from where you got that HTML source.

Highlighted
Developer
Posts: 76
Registered: ‎03-15-2010
My Device: 9800, 9630
My Carrier: Rogers

Re: Browser Field2 HTML Source?

Thanks for the response. Seems silly that there wouldn't be an easier way to get at information which is already there at some level.

 

Thanks for the suggestion though, I will try doing it that way.

 

Jason