Which call changes an ImageView's picture to another drawable at run time?
- img.text = R.drawable.x
- setContentView(R.drawable.x)
- img.loadUrl(R.drawable.x)
- img.setImageResource(R.drawable.studentsara)
Answer
D) img.setImageResource(R.drawable.studentsara)
setImageResource sets a drawable resource by ID.
Computer Science MCQ · More Lab: Student Information App Using Resources MCQs · Practise