Hello everyone, I am trying to downlaod a file from the net. It is an mp3 file and big in size. I m able to get connection but when trying to create a bufffer for file, I get out of memory exception.... please help its urgent... Code is: URL u = new URL("http://----------"); URLConnection uc = u.openConnection(); int contentLength = uc.getContentLength(); InputStream raw = uc.getInputStream(); InputStream in = new BufferedInputStream(raw); byte [] data=new byte[contentLength]; //getting outofmemory exception here..
--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~----------~----~----~----~------~----~------~--~---