JTable and sorting

Discussion in 'Java' started by RollNick, Jan 23, 2004.

  1. RollNick

    RollNick Guest

    i've got a problem with sorting JTable. Has anybody a solve of that problem,
    (actually source code ) :)?
    RollNick, Jan 23, 2004
    #1
    1. Advertising

  2. In article <buroe2$c73$>,
    "RollNick" <> wrote:

    >:i've got a problem with sorting JTable. Has anybody a solve of that problem,
    :mad:actually source code ) :)?
    >:
    >:


    <http://java.sun.com/docs/books/tutorial/uiswing/components/table.html>

    That goes to the tutorial page on JTable. One of the things it includes
    is a disussion of sorting your data. I was able to learn from that what
    I needed to devise a more complex table than the one included in the
    tutorial, and adapted its sorting discussion to my own app as well.

    = Steve =
    --
    Steve W. Jackson
    Montgomery, Alabama
    Steve W. Jackson, Jan 23, 2004
    #2
    1. Advertising

  3. "RollNick" <> writes:

    > i've got a problem with sorting JTable. Has anybody a solve of that problem,
    > (actually source code ) :)?


    What *actual* problem do you have?
    Tor Iver Wilhelmsen, Jan 24, 2004
    #3
  4. RollNick

    Tim Ward Guest

    "RollNick" <> wrote in message
    news:buroe2$c73$...
    > i've got a problem with sorting JTable. Has anybody a solve of that

    problem,
    > (actually source code ) :)?


    The version in the tutorial doesn't work (wrt selection) (the architecture
    in fact can't work no matter what you do with the code so there can be no
    solution). All the other free versions I could find didn't work either for
    one reason or another.

    So I wrote one that did work. But I'm afraid I can't post it because it
    belongs to my client.

    --
    Tim Ward
    Brett Ward Limited - www.brettward.co.uk
    Tim Ward, Jan 26, 2004
    #4
  5. Tim Ward <> wrote:
    > "RollNick" <> wrote in message
    > news:buroe2$c73$...
    >> i've got a problem with sorting JTable. Has anybody a solve of that

    > problem,
    >> (actually source code ) :)?

    >
    > The version in the tutorial doesn't work (wrt selection) (the architecture
    > in fact can't work no matter what you do with the code so there can be no
    > solution).


    Yes, it can.

    http://groups.google.com/groups?selm=




    Christian
    --
    And in short, I was afraid.
    Christian Kaufhold, Jan 26, 2004
    #5
  6. RollNick

    Tim Ward Guest

    "Christian Kaufhold" <> wrote in message
    news:...
    > Tim Ward <> wrote:
    > > "RollNick" <> wrote in message
    > > news:buroe2$c73$...
    > >> i've got a problem with sorting JTable. Has anybody a solve of that

    > > problem,
    > >> (actually source code ) :)?

    > >
    > > The version in the tutorial doesn't work (wrt selection) (the

    architecture
    > > in fact can't work no matter what you do with the code so there can be

    no
    > > solution).

    >
    > Yes, it can.
    >
    > http://groups.google.com/groups?selm=


    At a quick glance that appears to make my point for me - it can't be done
    within the architecture of the tutorial example, the code you point to has
    to break out of this architecture and override JTable itself, which is also
    how I did it (although rather more transparently for the user than I think
    is the case with the code you point to).

    --
    Tim Ward
    Brett Ward Limited - www.brettward.co.uk
    Tim Ward, Jan 27, 2004
    #6
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Brian J. Sayatovic

    Sorting a JTable with a delegating TableModel

    Brian J. Sayatovic, Jul 10, 2003, in forum: Java
    Replies:
    2
    Views:
    1,534
    Kleopatra
    Jul 15, 2003
  2. Tivo Escobar
    Replies:
    1
    Views:
    7,275
    manusa
    Apr 12, 2007
  3. Monique Y. Mudama
    Replies:
    1
    Views:
    443
    Monique Y. Mudama
    Jun 28, 2005
  4. Tintin92
    Replies:
    1
    Views:
    1,676
    Andrew Thompson
    Feb 14, 2007
  5. Haircuts Are Important
    Replies:
    3
    Views:
    302
    Haircuts Are Important
    Jun 4, 2013
Loading...

Share This Page