01-27-2010 09:33 PM
i am currently doing some bulk downloads of small .png files. The filepaths are parsed from an xml file, then downloaded, then passed to Bitmap.createBitmapFromPNG() as a Byte array.
The Bitmaps are created perfectly one after another, the function passing the paths is synchronized, no problems so far. just when I pass files of about 50Kb, (haven't tried bigger ones) it throws the IllegalArgumentException.
Solved! Go to Solution.
01-28-2010 05:00 AM
I would immediately suspect some corruption in the transfer. Take a really small file, send it down, dump out the bytes that you get to make sure that they really are the same as you expect from the same dump on the Server.
One perhaps easier option is to do this and save onto SD Card, then use PC software to do the compare.
02-09-2010 01:29 PM
it was the DownloadCombiner routine from the KB that failed, the file did not seem to have a size defined so the DC kept downloading until a timeout. In this case I just cancel the routine after a few runs. If the file cannot be opened afterwards I delete it and skip it. Else the file is perfect, size as expected, can be used normal.