您的位置: 首页 > IT文章 > 根据图片名字在drawable中得到图片 根据图片名字在drawable中得到图片 分类: IT文章 • 2022-05-21 11:37:18 int imageId = context.getResources().getIdentifier("图片的名字","drawable", "包名"); //iv是ImageView iv.setImageResource(imageId );