乌里设置不好的时候位错误 [英] bad bitmap error when setting Uri

查看:74
本文介绍了乌里设置不好的时候位错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想提出一个ImageView的网站上显示图像。所以,我创建了一个新的ImageView和执行 imgView.setImageURI(URI);

I would like to make an ImageView display an image on a website. So I create a new ImageView and execute imgView.setImageURI(uri);

当我启动应用程序中的图像不会出现,我得到的错误,resolveUri没有坏的位图URI(URI)。

When I launch the app the image does not appear and I get the error, "resolveUri failed on bad Bitmap Uri (uri)".

在如何解决这个任何想法?

Any ideas on how to solve this?

推荐答案

嗯......你需要下载的图像,然后将其设置为位图。 这里是众多例子之一。 的http://android-developers.blogspot.com/2010/07/multithreading-for-performance.html

Um.. you need to download the image and then set it as bitmap. Here is one of the many examples. http://android-developers.blogspot.com/2010/07/multithreading-for-performance.html

这篇关于乌里设置不好的时候位错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆