I have a file called nochart.png
in /drawable
.
How can I set this to an ImageView
?
chartImageView.setImageDrawable(R.drawable.nochart);
Does not compile.
just put your .png file in mipmap folder
Use:
chartImageView.setImageResource(R.drawable.nochart);
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With