Android 删除tablelayout中的tableRows
我尝试使用以下方法删除tableLayout中的行:Android 删除tablelayout中的tableRows,android,xamarin,rows,tablelayout,dynamically-generated,Android,Xamarin,Rows,Tablelayout,Dynamically Generated,我尝试使用以下方法删除tableLayout中的行: table.removeallview() table.RemoveAllViewInLayout() table.RemoveViewAt() 但它不起作用 所有我的行都是动态添加的。 感谢您的帮助。如果要清除所有表格,可以使用以下方法在for循环中逐个删除表格子项: int count = table.getChildCount(); for (int i = 0; i < count; i++) { View chil
table.removeallview()
table.RemoveAllViewInLayout()
table.RemoveViewAt()
感谢您的帮助。如果要清除所有表格,可以使用以下方法在for循环中逐个删除表格子项:
int count = table.getChildCount();
for (int i = 0; i < count; i++) {
View child = table.getChildAt(i);
table.removeView(child);
}
int count=table.getChildCount();
for(int i=0;i
您能粘贴代码吗?编辑您的问题以添加其他详细信息,如您的代码、计时器信息以及发生的情况