I have overrided the method isCellEditable(), and return false. Now, the users can not modify the data on JTable anymore, however, they can move the column on JTable. How can I rivet the column on JTable? In other words, how to prevent the users to move the column on JTable? Thank you!!!
SCJP<br />SCJD
ZhengQi Huang
Greenhorn
Joined: Aug 13, 2002
Posts: 9
posted
0
You can try this: table.getTableHeader().setReorderingAllowed(false);
I am a beginner.
friso dejonge
Ranch Hand
Joined: Jul 11, 2002
Posts: 162
posted
0
hi richard, further, the java tutorial does give a great example on the jtable, the model and loads of ways of changing it. regards, friso
swimming certificate (A & B), shoelaces diploma, and some useless java ones.
Richard Phen
Ranch Hand
Joined: Apr 27, 2002
Posts: 52
posted
0
Thank you Huang! I fixed it with your suggestion. One more question: I did not find out this method-setReorderingAllowed(boolean) from jdk1.3 api documents. Would you tell me where is this method defined?