Have you (maybe erroneously) declared your own class DocumentListener
somewhere else? i.e. what happens if you change
tekstveld.getDocument().addDocumentListener(new DocumentListener(){
to
tekstveld.getDocument().addDocumentListener(new javax.swing.event.DocumentListener(){
?
(Although, on an related note, I agree with the comment, above, that setting a document listener inside your action performed method seems like a bad idea; this should be set when your form is being created..)