This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Swing / AWT / SWT and the fly likes Table cells value changing on double click Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "Table cells value changing on double click" Watch "Table cells value changing on double click" New topic
Author

Table cells value changing on double click

Bill White
Ranch Hand

Joined: Oct 27, 2002
Posts: 82
I have asked this question before. What I have is a class that I have written that hold some data.
I place objects of this class in the first column of each row so when I double click on a row I have easy access to a particular piece of info about that row.
However, when I double click on the cell that has my object in it. The type gets changed from CellValue (The name of my class) to String.
Is there a way I can stop this particular behavior?
Thank you.
Paul Stevens
Ranch Hand

Joined: May 17, 2001
Posts: 2823
If you are just using that column for reference, set editing to false.
Bill White
Ranch Hand

Joined: Oct 27, 2002
Posts: 82
I dont see where you can do that.
Bill White
Ranch Hand

Joined: Oct 27, 2002
Posts: 82
I figured a way around the problem. I put my class that is holding the data I am worried about in another column and hid it.
 
Don't get me started about those stupid light bulbs.
 
subject: Table cells value changing on double click
 
Similar Threads
disable previous JFrame upon new JFrame popup
TableModels value getting changed
JTable's Cell Text append Problem
Selecting a particular row in <table> tag used.
JTable Cell Editor