Discussion:
jtextfield settext not working :(
(too old to reply)
6e
2006-01-20 15:05:19 UTC
Permalink
Hi,

I have created an extended JTextField class that also contains an
extends PlainDocument class as shown on sun's web site under JTextField

http://java.sun.com/j2se/1.5.0/docs/api/javax/swing/JTextField.html

However Im having a bit of a problem with setting the text of the
field. It works when I first instantiate the object (i.e. new
myJtextField("Hi")) but does not work when I am trying to
programmatically set the text of the object using setText("Bye");

I tried calling invalidate and validate and neither seem to work.

after I try to use setText the myJTextField goes blank.

let me know if you have any ideas!
Thanks
6e
2006-01-20 15:43:34 UTC
Permalink
whoops, just a lojoc problem,,, thanks anyways!

Continue reading on narkive:
Loading...