Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Hiding a coulmn of JTable

 
Manoj Tyagi
Ranch Hand
Posts: 35
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi everybody,
I am having a JTable TableColumnModel with 6 coulmns. Now while inserting/updating database i need the values of all columns but while to display user i want to hide 2 columns.
Thats I want to display only 4 columns of a JTable, however internally its model will have 6 columns.
How can i achieve this task of hiding any particular column from view.
Please help me out,
Waiting for the reply.
Manoj Tyagi
 
an ik
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi I think u can use JTable's removeColumn
see
http://java.sun.com/j2se/1.4.1/docs/api/javax/swing/JTable.html#removeColumn

goodluck
[ October 21, 2002: Message edited by: an ik ]
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic