JTextField

In a Textfield I want to restrict my typing to 6charecters can some one help me.
[87 byte] By [Dharmendra.jspa] at [2007-11-27 4:56:50]
# 1
Use a JFormattedTextField and use a MaskFormatter.
camickra at 2007-7-12 10:12:08 > top of Java-index,Desktop,Core GUI APIs...
# 2
i AM NOT GETTING PLZ TELL ME ........i WANT TO CHANGE THE INPUT CHARECTERS TIME TO TIME...................THAT MAY BE LETTER OR ANY THING
Dharmendra.jspa at 2007-7-12 10:12:08 > top of Java-index,Desktop,Core GUI APIs...