1

I am developing an app in which the user needs to download videos, pdf, and images from our server. The server response is base64binary data. I am able to download small videos but getting out of memory exception while handling large video or pdf files. I saw the post Android: out of memory exception in Gallery and Very large SOAP response - Android- out of memory error but I didn't find any solutions.

The error I am receiving is in the line.. HttpTransportSE.call(soapAction, soapEnvelope) method.

How can I tackle this situation and download the files.

Community
  • 1
  • 1
G K
  • 66
  • 7
  • so nobody is here to help me with this. I tried a lot and found that the request is too large and hence the out of memory error is popping. I am unable to get how the request is getting so large and consuming memory. – G K Aug 27 '12 at 05:03
  • Problem is all data received is loaded in memory, so one solution is NOT to use ksoap library but using instead HttpUrlConnection class and reimplement your connection. By that class, you can save all data received directly on disk. Unfortunally ksoap doesn't provide a way to decide where you can save data when you receive it. – kinghomer Oct 04 '12 at 12:57
  • Thanks for the info Kinghomer, but can you please tell me how to connect with Soap using httpurlconnection??? – G K Oct 04 '12 at 16:27

1 Answers1

1

I verified and tested a fix for using Soap and saving data directly as file. See link

https://stackoverflow.com/a/12732396/736196

Follow post's indications and it will work

Community
  • 1
  • 1
kinghomer
  • 3,021
  • 2
  • 33
  • 56