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: 58
Registered: ‎07-09-2009
My Device: Blackberry Bold

Re: Loading web images on actual BB device issue

Ah yes.. this adds a nice layer of complication to my application if the device is not on BES.. wonderful..

 

Thanks for all your help on this topic. I appreciate it.

Developer
Posts: 4,764
Registered: ‎07-21-2008
My Device: Not Specified

Re: Loading web images on actual BB device issue

Yes, welcome to the world of Blackberry.

 

Look at it this way, if it were easy, they woulddn't need to pay us the big bucks!

 

Smiley Happy

 

Developer
Posts: 58
Registered: ‎07-09-2009
My Device: Blackberry Bold

Re: Loading web images on actual BB device issue

One more quick question...

 

I just switched my SIM card from my BB Bold to my old BB Curve. Why is it that my on BB Curve that is not connect to BES the application works fine then? It downloads all the images and all the webservices work fine.. is that supposed to happen?

 

This HTTP connection stuff is starting to get me reaalll confused..

 

Developer
Posts: 4,764
Registered: ‎07-21-2008
My Device: Not Specified

Re: Loading web images on actual BB device issue

[ Edited ]

What network is that Curve on?  Probably Verizon?

 

 

 

 

 

 

 

Message Edited by RexDoug on 07-27-2009 05:14 PM
Developer
Posts: 58
Registered: ‎07-09-2009
My Device: Blackberry Bold

Re: Loading web images on actual BB device issue

Well interestingly enough the phone it worked on is att. However I have a friend who has t-mobile for which neither the webservices nor the images get loaded. Not sure how a verizon application would react to the application yet.
Developer
Posts: 4,764
Registered: ‎07-21-2008
My Device: Not Specified

Re: Loading web images on actual BB device issue

Try appending this string to your URL on the T-Mobile device:

 

";deviceside=true;apn=wap.voicestream.com"

 

 

 

 

Developer
Posts: 58
Registered: ‎07-09-2009
My Device: Blackberry Bold

Re: Loading web images on actual BB device issue

I'm assuming these APN suffixes need to be appened on for most phone carriers..

 

Well thanks for your help. I understand what I need to do now. I will try to post some working code samples when I complete my testing on devices.

 

 

Developer
Posts: 58
Registered: ‎07-09-2009
My Device: Blackberry Bold

Re: Loading web images on actual BB device issue

Found a great resource for people having trouble with connections on the blackberry.


 

Word press has an open source app with a great example of how to form connections with/without BES and BIS.

 

You can find it here:

http://blackberry.svn.wordpress.org/trunk/src/com/wordpress/utils/conn/

 

Highlighted
Developer
Posts: 58
Registered: ‎07-09-2009
My Device: Blackberry Bold

Re: Loading web images on actual BB device issue

Also if anyone is using the "WebBitmapField" that they found online.

There is a a small bug in the "public static void getWebData(final String url, final WebDataCallback callback)" method.


The following line of code:
connection = (HttpConnection) Connector.open(url, Connector.READ, true); 

Needs to be changed to
connection = (HttpConnection) Connector.open(url, Connector.READ_WRITE, true); 
This happens in 4.5+.

I found the reasoning behind it here: http://www.coderholic.com/blackberry-os-45-connection-not-writeable-error/