How to add check box in table row.

Hi,
In my plugin iam creating the table using DefaultTableModel. I want to add a check box as first coulmn in all rows. How can i do this.

3 comments
Comment actions Permalink

You can do this in exactly the same way as you would do this in any other Swing application.


0
Comment actions Permalink

Hi,
Sorry for delay in reply..
Sorry, i didnot get you. I have a jtable. In the table only first column will be checkbox, all other columns will be some data.
For creating the roe iam doing
model.addRow(new Object[]{templateResource.getTemplateName(), templateResource.getTemplateDescription(), fileNames.replaceFirst(",", "")});
This is creating a row wirh data, but the problem is here i cannot add check box, i want to know along with these data, how to add check box as the firts column in the row.

Thanks,
Mangala

0
Comment actions Permalink

This is a question about Swing, not about IntelliJ plugin development. Adding a checkbox to a JTable does not require using any IntelliJ specific APIs.

0

Please sign in to leave a comment.