第1个回答 推荐于2016-04-28
try {
URL url = new URL(urlpath);
URLConnection con = (URLConnection) url.openConnection();
InputStream stream = con.getInputStream();
Bitmap bitmap = BitmapFactory.decodeStream(stream);
img.setImageBitmap(bitmap);
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}本回答被提问者和网友采纳