public void filter (String text,TableRowSorter sorter) {
           if (text.length() == 0) {
                 sorter.setRowFilter(null);
           } else {
                try {
                    sorter.setRowFilter(
                    RowFilter.regexFilter(text));
                } catch (PatternSyntaxException e) {
                    Error_Frame.Error(e.getPattern());
                }
           }
    }