04-20-2011 09:55 AM
Every once in a while I get a java.lang.OutOfMemoryError error when downloading a lot of text content to my app. I'm not sure exactly what causes it, but wondering if there are any good practices to handle/prevent this from happening. My current plan is to try/catch in certain areas of the application and exit since an app restart works.
04-20-2011 04:24 PM
which OS version are you running on... 5 or 6... how much text roughly are you downloading via what method... was just gonna see if can get it happening too..
04-20-2011 06:18 PM
Issue is on version 5 (8530 sim). I'm downloading about 5.5MB of text broken up into 400KB junks at a time. Each chunks is delimited into a number of "pages" of content, totaling over 600 (includes text and base64 images). Then I create an key/value object that takes in all the pages and makes that data available offline in memory.