-1
rs = statement.executeQuery(query);
List<Map<String, String>> data = null;
data = new ArrayList<Map<String,String>>();
while(rs.next()){
Map<String, String> datanum = new HashMap<String, String>();
datanum.put("A", rs.getString("Nome").trim().toString());
datanum.put("B", "http://acme.com.br/pic/1/" + rs.getString("Al_Matricula").trim().toString() + ".jpg"); // <<<--- URL
datanum.put("C", rs.getString("Id").trim().toString());
datanum.put("D", rs.getString("Ean").trim().toString());
datanum.put("E", rs.getString("Code").trim().toString());
data.add(datanum);
}
String[] from = {"A", "B", "C", "D", "E"};
int[] views = { R.id.tvNome,
R.id.tvTemp, // <<<---- preciso que meu imageview que esta dentro do listview carregue esta imagem
R.id.tvId,
R.id.tvEan,
R.id.tvCode };
AD = new SimpleAdapter(this, data, R.layout.activity_modelo, from, views);
lst_Alunos.setAdapter(AD);
There are some libraries that you can use like Picasso or Glide, with them you can easily load the images from the url and still manage to cache. Glide Picasso
– Guilherme Montanher
I’ve tried to implement with Glide and Picasso, but I’m not finding how to implement according to my need.
– Mr Magoo
Related: I can put an image of the internet on an Imagebutton?.
– ramaral