public void setTableModel(List<Users> users) {
eraseTableRows();
for (int i = 0; i < users.size(); i++) {
Users u = users.get(i);
tm.insertRow(i, new Object[] { stuff });
}
}
private void eraseTableRows() {
for (int i = 0; i > tm.getRowCount(); i++) {
tm.removeRow(i);
}
i've tried this and the setRowCount and none of these work
Thanks in advance