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
Regular Contributor
Posts: 58
Registered: ‎10-21-2010
My Device: Bold 9700
My Carrier: DTAC

BrowserField Problem

I use a BrowserField to request contents from URL and submit from. I configure browserfield like this :

browserConcig = new BrowserFieldConfig();
    browserConcig.setProperty(BrowserFieldConfig.NAVIGATION_MODE,
        BrowserFieldConfig.NAVIGATION_MODE_POINTER);
    browserConcig
        .setProperty(BrowserFieldConfig.JAVASCRIPT_ENABLED, Boolean.TRUE);
    browserConcig.setProperty(BrowserFieldConfig.ALLOW_CS_XHR, Boolean.TRUE);
    browserConcig.setProperty(BrowserFieldConfig.INITIAL_SCALE, new Float(0.58));
    browserConcig.setProperty(BrowserFieldConfig.USER_SCALABLE, Boolean.FALSE);
    browserConcig.setProperty(BrowserFieldConfig.VIEWPORT_WIDTH, new Integer(
        Display.getWidth()));
    
    browserField = new BrowserField(browserConcig);

 and call requestContent  method

 

browserField.requestContent(URL);

 It work fine when I test which Bold 9700 (both device and Simulator) but when I test with Curve 8520 (OS5  and OS6 both device and simulator) I got this error show in BrowserField:

 

 

Does anyone know what does it mean?

Thanks

Regards

 

error.png

Highlighted
Regular Contributor
Posts: 58
Registered: ‎10-21-2010
My Device: Bold 9700
My Carrier: DTAC

Re: BrowserField Problem

I try to use 

Browser.getDefaultSession().displayPage(url);

and it work fine.

 

How to make BrowserField show like the Browser does?

 

Thanks 

Regards