android activity - listView- how can you make each item clickable -
i have list of items on listview when 1 pressed open new activity. can help?
this question potentially google-able i'll put code here anyway.
listview can have listener attached listens clicks of list items:
listview.setonitemclicklistener(new listview.onitemclicklistener() { public void onitemclick(adapterview<?> parent, view view, int position, long id) { youritemtype item = (youritemtype)parent.getadapter().get(position); yourinfo info = item.getinfo(); intent intent; //instantiate intent here info startactivity(intent); } });
Comments
Post a Comment