I am getting an error when trying to set my view to display the ListView for the file I want to display(text file). I am pretty sure it has something to do with
ListView
Soution is here
listitem.xml
Java code :
String[] countryArray = {"India", "Pakistan", "USA", "UK"}; ArrayAdapter adapter = new ArrayAdapter(this, R.layout.listitem,R.id.textview, countryArray); ListView listView = (ListView) findViewById(R.id.listview); listView.setAdapter(adapter);