K. Tsang wrote:How are you getting or generating your column name? Do you using the default table model or making your own?
i want to make my own table ....but instead of string"title 1" must be checkbox
table contents -checkbox (Title1), Name(Title2), LastName(Title3)....
In your table model, you should override the getColumnName() method and assign a empty string "" to it. Then in your getColumnClass() method, return Boolean.class for that column. This should give what you want.
That would work for the JTable itself, but the JTableHeader needs special support. Apart from the renderer Michael talked about you would also require a listener (probably MouseListener) to handle the toggling.