Using java Syntax Highlighting
- URL sourceURL = new URL(urlStr);
- URLConnection con = sourceURL.openConnection();
- con.setRequestProperty("Content-Range", "bytes 0-200/"+pbMax); //sets
- a chunck to download
- InputStream inStream=(InputStream)con.getContent();
- int pbMax =con.getContentLength();
- Log.w("TAG",""+pbMax); //but this returns the full length
Parsed in 0.032 seconds, using GeSHi 1.0.8.4
THis downloads the full content even if i set a part to download.
Please have a look
Thank you

