0
我正在動態創建Expandablelistview,如下所示,其中展開列表包含edittext和複選框。Android動態添加Expandablelistview返回null爲findviewbyid
ExpandableListView epView = new ExpandableListView(this);
mAdapter = new MyExpandableListAdapter();
epView.setAdapter(mAdapter);
LinearLayout ll = (LinearLayout) findViewById(R.id.myLayout);
ll.addView(epView);
我在LinearLayout ll
一個提交提交我試圖讓使用的EditText ID的擴展列表中的值按鈕。我正在獲取移動屏幕中顯示的擴展項目的值,但是對於findviewbyid,摺疊狀態項目返回null。有人能爲我解決這個問題嗎?
我的一個FRND做了一個很好的教程選中此[鏈接](http://coderzheaven.com/index.php/2011/04/expandable-listview-in-android-using-simpleexpandablelistadapter-a -simple-example /) – 2011-04-27 15:29:16