JTable: Row and Cell Selection

Discussion in 'Java' started by QL23, Apr 4, 2017.

  1. QL23

    QL23

    Joined:
    Apr 4, 2017
    Messages:
    1
    Likes Received:
    0
    Hi everyone.

    Currently, I am new to the Java Swing and Jtable. I'm hoping anyone could help me. I'm trying to work on a functionality such as:

    Table with 4 column { a, b, c, d} with 4 rows.
    - I should able to select a cell in column b, however, if I select any cell in column a, c or d, the whole row of the selected cell will be select.

    The behavior I'm trying to do is if I select cell { row 1, column b} - cell is selected, then select {row 3, column a} the whole row 3 is highlighted. Where the cell is selected in column b row 1 as well as the whole row 3.

    Is there anyone have any information to work on this behavior in jtable?
     
    QL23, Apr 4, 2017
    #1
    1. Advertisements

  2. QL23

    John Joe

    Joined:
    Apr 25, 2017
    Messages:
    98
    Likes Received:
    14
    Location:
    Malaysia
    What have you tried? Have you done created a JTable ? :)
     
    John Joe, Apr 26, 2017
    #2
    1. Advertisements

Ask a Question

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

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.