Closed coderazzi closed 9 years ago
Original comment by coderazzi coderazzi (Bitbucket: coderazzi, GitHub: coderazzi).
Hi, Antoine, thanks for submitting the issue; I am using a slightly different code that makes no usage of your ExtendedCoderazziFilter.
#!java
import java.awt.*;
import javax.swing.*;
import javax.swing.table.*;
import net.coderazzi.filters.*;
import net.coderazzi.filters.gui.*;
public class Issue_39 {
public static void main(String args[]) {
JFrame frame = new JFrame();
frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
Object rowData[][] = { { "Str1" , true, new Double(1) },
{ "Str2" , true, new Double(2) },
{ "Str3" , false, new Double(3) },
{ "Str4" , true, new Double(4) },
{ "Str5" , false, new Double(5) } };
Object columnNames[] = { "String", "BOO", "Double" };
DefaultTableModel model = new DefaultTableModel(rowData, columnNames);
JTable table = new JTable(model);
TableFilterHeader jFilter_RunsTable = new TableFilterHeader( table, net.coderazzi.filters.gui.AutoChoices.DISABLED);
jFilter_RunsTable.getFilterEditor( 2 ).setAutoChoices( net.coderazzi.filters.gui.AutoChoices.ENABLED );
JScrollPane scrollPane = new JScrollPane(table);
frame.add(scrollPane, BorderLayout.CENTER);
frame.setSize(300, 150);
frame.setVisible(true);
}
}
It still shows the same error you report...
Original comment by Antoine Guillou (Bitbucket: [Antoine Guillou](https://bitbucket.org/Antoine Guillou), ).
I confirmed that the problem is solved. Thanks :+1:
Original report by Antoine Guillou (Bitbucket: [Antoine Guillou](https://bitbucket.org/Antoine Guillou), ).
Hey Luis, Thanks for your great filter!
I noticed a problem when filtering a column which has:
values of class double, but in fact all are integers values ( Double(1), Double(2), ... ).
AutoChoices.ENABLED
In the example above, filtered the column "Double" with ">=3" and click anywhere in the table. Then the filter value become "5"....