JTable's Cell Validate

Hi, I want to validate the value of a particular cell of the table at the time of key typed. plz let me know how can i achieve
[154 byte] By [jaimatadi@12a] at [2007-11-27 7:01:43]
# 1
One way would be to get the CellEditor for the column your are working with and obtain the JTextComponent (JTextField) used to input the text and attach a CaretListener to it. Then you can validate the text as it is typed.
icewalker2ga at 2007-7-12 18:52:35 > top of Java-index,Desktop,Core GUI APIs...
# 2

To edit text as it is typed into a text component you should use a DocumentFilter. Read the Swing tutorial on [url http://java.sun.com/docs/books/tutorial/uiswing/components/generaltext.html#filter]Implementing a Document Filter[/url].

Or, you could try using a JFormattedText field as the editor for the cell.

camickra at 2007-7-12 18:52:35 > top of Java-index,Desktop,Core GUI APIs...
# 3
thanks buddy, it solved my problem.
jaimatadi@12a at 2007-7-12 18:52:35 > top of Java-index,Desktop,Core GUI APIs...