I have a tabhost layout with a list in each tab. I am trying to make a listview in a listview like the default music player on the droid, or when clicking on a listview bring up a menu with a list of options (about 7) to choose from. I'm really trying for the former but I can't find anyway to do it, I've tried onListItemClick going to another activity where I will define another list, but it won't work because of errors that I cannot seem to fix to get it working properly.
any ideas?
Code:
@Override
public void onCreate(Bundle savedInstanceState)
{
final String[] CDExplorer_tabs = new String[] {"item1", "item2", "item3", "item4", "item5"};
super.onCreate(savedInstanceState);
setListAdapter(new ArrayAdapter<String>(this, R.layout.list_item, CDExplorer_tabs));
ListView lv = getListView();
lv.setTextFilterEnabled(true);
registerForContextMenu(lv);
public void onListItemClick( ListView parent, View v, int position, long id)
{
final Intent i = new Intent(this, CDETabs.class);
startActivity(i);
}
}
}
any ideas?