my list view is not selectable
hi i make this tutorial http://techdroid.kbeanie.com/2009/07/custom-listview-for-android.html
but i can't select thi item in the listview..
how can i resolve this??
i don'y understand the comments on the blog..
maybe the problem are in here
ListView list = (ListView)findViewById(R.id.ListView_addConta);
DBAdapter db = new DBAdapter(Contas.this);
db.open(); 开发者_如何学编程
List<Conta> listOfConta = db.getContas();
ContaAdapter adapter = new ContaAdapter(this, listOfConta);
list.setAdapter(adapter);
Extend ListActivity
instead of Activity
, and override the onListItemClick
method. This way works best for me.
This is a good tutorial: http://www.vogella.de/articles/AndroidListView/article.html
精彩评论