String[] items = { "Item 1","Item 2","Item 3","Item 4"};
ListView myListView = (ListView) findViewById(R.id.myListView);
ArrayAdapter<String> adapt = new ArrayAdapter<String>(this, android.R.layout.simple_list_item_1, items);
myListView.setAdapter(adapt);
沒有留言:
張貼留言