2012-05-12 51 views

回答

0

row =(TableRow)findViewById(R.id.row); table.removeView(row);

+0

thank you.it works –

0
TableLayout tblLayout = (TableLayout) findViewById(viewID); 
tblLayout.removeAllViews(); 
0

一个简单的方法来这样做,它将设置行已经消失。

TableLayout tableLayout = findByViewId(R.layout.myTL); 
tableLayout.getChildAt(numberOfRow).setVisibility(View.GONE); 

希望此解决方案适合您的情况!