I have a List View which is populated with countries I want to be able to click a an item and have it go to another activity in which i play an audio. my list View:
public class MainActivity extends ListActivity {
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
setListAdapter(new ArrayAdapter<String>(this, android.R.layout.simple_selectable_list_item,getResources()
.getStringArray(R.array.countries)));
}
}
How do I go about adding a onClick just like how you would make one for a button??