Code example for ListView

Methods: setAdapter, setOnItemClickListener

0
    		startActivity(new Intent(this, SetupInternetActivity.class)); 
        } 
    } 
	public void fillListview(String _lvPods_arr[])
	{ 
        lvPods.setAdapter(new ArrayAdapter<String>(this, android.R.layout.simple_list_item_1, _lvPods_arr));
        lvPods.setOnItemClickListener(new OnItemClickListener(){
			public void onItemClick(AdapterView<?> a, View v, int position, long id) {
				//onclick put select pod to editTextCurrentpod 	 
			    editTextCurrentpod.setText(lvPods.getItemAtPosition(position).toString());
			} 
        }); 
	} 
	//Screen orientation crashes app fix 
	//http://jamesgiang.wordpress.com/2010/06/05/screen-orientation-crashes-my-app/ 
	@Override 
	public void onConfigurationChanged(Configuration newConfig) 
	{ 
		super.onConfigurationChanged(newConfig);
	}  
	// Handle the Back button