나는 "putExtra"로 Image를 전달하고 "getExtra"를 사용하여 다른 Activity에서 가져 오기를 클릭하는 List Item을 가진다. 거기에 몇 가지 해결책을 설명하지만 그 중 아무도 나를 위해 일하고 Stackoverflow에 비슷한 질문이 있습니다.getExtra에서 이미지 URL을 받고이를 설정하는 방법
첫 번째 활동 : 나는 두 번째 활동을 검색 할 때
listview.setOnItemClickListener(new AdapterView.OnItemClickListener() {
@Override
public void onItemClick(AdapterView<?> arg0, View arg1, int position, long id) {
intent.putExtra("imageurl", elementList.get(position).getImage());
startActivity(intent);
}
});
, 난 아무것도 얻을 수 없다.
E/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException: https:/tctechcrunch2011.files.wordpress.com/2017/05/battlefield-africa-sponsored.png?w=764&h=400&crop=1 (No such file or directory)
두 번째 활동 : 내가 그것을
'elementList.get (position) .getImage()'가 반환하는 값은 무엇입니까? –
문자열 URL을 반환합니다. 다음과 같이 : ""https://tctechcrunch2011.files.wordpress.com/2017/05/battlefield-africa-sponsored.png?w=764&h=400&crop=1 " – user45678