0

for adding a row in a tablelayout, the code can be done as follows:

   private void ToDisplayTagGUI(String Slot, int index)
      LayoutInflater inflater = (LayoutInflater) getSystemService(Context.LAYOUT_INFLATER_SERVICE);
      View newTagView = inflater.inflate(R.layout.new_tag_view, null);
      SlotTableLayout.addView(newTagView, index);

for removing the whole tablelayout's data, the code can be as follows:

      SlotTableLayout.removeAllViews();

how could i do so if i just want to remove one of the rows from the tablelayout?

pearmak
  • 4,979
  • 15
  • 64
  • 122

1 Answers1

1

To remove particular row from tablelayout you can use :

table.removeView(rowindex);

Devrath Rathee
  • 74
  • 2
  • 12