>> [code and stuff]
>
> Thanks ak, I used some of yours and some stuff from the Sun website and
> got it to work! Great stuff
Hmm, maybe not...
I use the method to check that the input is a number key, and then add
that to an internal string. Then I want the box text to be set to
something else based on that (a currency-formatted string). The problem
is that insertString only appends text and I want it to replace the
existing text after every key-press.
So I tried using the super.replace() method, but I think that uses
insertString so it starts infinitely recursing til there's a stack
overflow.
Any ideas?

Signature
Nick H
ak - 11 Feb 2004 16:53 GMT
> I use the method to check that the input is a number key, and then add
> that to an internal string. Then I want the box text to be set to
[quoted text clipped - 4 lines]
> insertString so it starts infinitely recursing til there's a stack
> overflow.
you should use super.insertString().
may be you also coulduse JFormattedTextField.
--
____________
http://reader.imagero.com the best java image reader.