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
Highlighted
New Contributor
Posts: 3
Registered: ‎03-15-2012
My Device: 8520
My Carrier: Movistar
Accepted Solution

XML in "Memory" httpconnection

HI! I am developing an app that reads a xml file in my webpage...

 

Its everything allright but the problems is that i modify the xml and when i open my app in the bb again the information is exactly the some...

 

any ideas?

 

im using httpconnection to open the connection and then i parse the xml...

 

I really do not know what is hapening.

 

This is how i read the url

 

HttpConnection conn = (HttpConnection) Connector.open(url + Transport, Connector.READ);
if ( conn.getResponseCode() == HttpConnection.HTTP_OK )

 

the i use DocumentBuilderFactory to parse the xml

 

Thank you very much

 

PD: I dont know why i write this topic under bb push development, please erase it from there

Developer
Posts: 729
Registered: ‎05-04-2011
My Device: 9700

Re: XML in "Memory" httpconnection

It's probably a cache issue.

 

Just add a time attribute to the URL, which will hold the current time in milliseconds and that will act as a cache buster:

For example, if your URL is: www.example.com, then you should use: www.example.com?time=%currentTimeInMillis%

 

E.

New Contributor
Posts: 3
Registered: ‎03-15-2012
My Device: 8520
My Carrier: Movistar

Re: XML in "Memory" httpconnection

Thank you very much! That was the solution!! THANK YOU