trouble converting image to a drawable, android
<p>I want to download an image and have it as a drawable in my object class</p>

<pre><code>for(int i=0;i&lt;jArray.length();i++){ 

            json_data = jArray.getJSONObject(i); 
            Programme Progresult = new Programme();

            Progresult.name = json_data.getString("name");
            Progresult.event = json_data.getString("event");
            Progresult.price = json_data.getString("price");


            String p = json_data.getString("preview");
            try {
                 is2 = (InputStream) new URL(p).getContent();
            } catch (MalformedURLException e) {
                // TODO Auto-generated catch block
                e.printStackTrace();
            } catch (IOException e) {
                // TODO Auto-generated catch block
                e.printStackTrace();
            }

            Progresult.progpreview = Drawable.createFromStream(is2, "src name");

            arraydata.add(Progresult);

            }
</code></pre>

<p>I'm getting some decode errors</p>

<pre><code>03-23 20:36:51.401: D/skia(795): --- decoder-&gt;decode returned false
03-23 20:36:51.680: D/skia(795): --- decoder-&gt;decode returned false
03-23 20:36:51.933: D/skia(795): --- decoder-&gt;decode returned false
03-23 20:36:52.450: D/skia(795): --- decoder-&gt;decode returned false
03-23 20:36:53.120: D/skia(795): --- decoder-&gt;decode returned false
</code></pre>

<p>I think it might be something god to do with the url to the image that is being retrieved, here is one of them....</p>

<pre><code>"http://ec2-##-###-##-###.eu-west-1.compute.amazonaws.com/corkgaa/Match%20programmes/sample1.bmp"
</code></pre>

<p>Any help appreciated :)</p>
