1 Reply Latest reply on Aug 8, 2011 4:36 PM by 801313

    JTables inside a JTable

      I have designed a Table (call it as MainTable) using swing JTable where each cell in this Table is rendered using a JTable(subTable1) with n columns and 1 row and the subTable1'srendering component is also a JTable(subTable2) with n columns and 1 row and this tables... (goes on). The depth of these subTable for a given Cell varies from 0 to n. All the tables have their own TableModel.

      As mentioned the row count of the subtable is always 1 and hence getValueAt and setValueAt functions are always called with rowIndex 1 which is trivial. Instead I need the rowIndex of the mainTable for which this subtable is used as rendering component.

      Does anyone know how this can be done?