How do I get the row id of a listView? The idea is this: before grabbing the selected line, I'll work with all the lines I'm trying.
aList = new ArrayList<HashMap<String,String>>();
for(int i=0;i<countries.length;i++){
HashMap<String, String> hm = new HashMap<String,String>();
hm.put("txt", getString(countries[i]));
aList.add(hm);
}
String[] from = { "txt" };
int[] to = { R.id.txt};
SimpleAdapter adapter = new SimpleAdapter(getActivity().getBaseContext(), aList, R.layout.listview_layout, from, to);
setListAdapter(adapter);
...
OnItemClickListener listener = new OnItemClickListener() {
@Override
public void onItemClick(AdapterView<?> arg0, View arg1, final int arg2, long arg3) {
for(int i=0;i< arg0.getCount();i++){
não sei fazer o setText(); em todos os 'R.id.txt'...
}
If someone has an idea how to do it, I appreciate the help.