Hi all,
I have a table where the user can add new rows by selecting a JButton. I have added a text box which allows the user to search for a String value and this filters the table contents and this is all working fine...But when I go to add a new row I get the following exception:
java.lang.IndexOutOfBoundsException: Invalid range
which seems to originate from
DefaultRowSorter.rowsInserted
Could someone please give me any ideas to why this is happening, maybe the number of rows that are in the table orginally is set to x and when I add a new row the TableRowSorter is expecting that number not x + 1 which is added due to the button being pressed?
Seems like I need to update the TableRowSorter to inform it that a new row has been added or something similar to that,
Thanks,