Results 1 to 2 of 2
  1. #1
    CoryC is offline Member
    Join Date
    Jul 2012
    Posts
    1
    Rep Power
    0

    Default Sorted JTable - keep row selection on sort

    Hello All,

    I have a JTable with a TableRowSorter. I've set setUpdateSelectionOnSort to false. When clicking on the column headers (where I toggle sort direction), it maintains the selected row properly.

    If I edit a sorted column however (causing it to resort), it does not follow the selection. The row position just stays while the row i was just editing get's sorted off to another spot. Is there some way I can avoid this?

    thanks!

  2. #2
    DarrylBurke's Avatar
    DarrylBurke is offline Member
    Join Date
    Sep 2008
    Location
    Madgaon, Goa, India
    Posts
    11,188
    Rep Power
    19

    Default Re: Sorted JTable - keep row selection on sort

    Moved from Advanced Java

    db
    If you're forever cleaning cobwebs, it's time to get rid of the spiders.

Similar Threads

  1. Replies: 6
    Last Post: 04-11-2012, 10:31 PM
  2. Selection Sort. please help!
    By cassato in forum New To Java
    Replies: 4
    Last Post: 03-14-2011, 10:26 PM
  3. Is this a Selection Sort?
    By Metastar in forum New To Java
    Replies: 2
    Last Post: 10-22-2010, 05:00 AM
  4. Problem with selection sort
    By Metastar in forum New To Java
    Replies: 6
    Last Post: 10-21-2010, 02:18 AM
  5. selection sort
    By mayhewj7 in forum New To Java
    Replies: 1
    Last Post: 04-29-2009, 12:40 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •