Win a copy of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

RowFilter dont show rows in JTable  RSS feed

 
a. arevalo
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

hi

im using sorter object (TableRowSorter) to filter and sort rows in jtable, but when i trying filter rows dont show the rows in jtable



when i type (a) on filterText object, jtable shows rows who values on column 1 had letter a (for now all is right), but when i hit backspace key on my keyboard
sorter.setRowFilter( null ); line is run, jtable dont show all rows (i think need update something to change take effect), and when i type (a) again jtable dont show
any rows...

i need something like sorter.update() method or something? or on jtable?

any help?

thanks in advance. (sorry for my english)
 
Rob Spoor
Sheriff
Posts: 21047
85
Chrome Eclipse IDE Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Check your console - you probably got a PatternSyntaxException, since "(a" is not a valid regular expression. This probably messes up your entire application.
 
a. arevalo
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thanks for answer Rob Prime, but no, the sintaxys is ok, when i type (a) for firts time all is right, and the excepcions dont show on console i catched on JOptionPane, the thing is jtable dont show(paint) the rows...

 
a. arevalo
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi

i found the way to rows can repaint, only need set the row sorter on table again... thanks =)



 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!