you missing break after most cases in your switch statement
peter_budo
Code tags enforcer
15,436 posts since Dec 2004
Reputation Points: 2,806
Solved Threads: 902
He wants that, because the song goes
On the twelveth Day of Christmas
My true love gave to me
12 Drmmers Drumming
11 Pipers Piping
10 .....
masijade
Industrious Poster
4,253 posts since Feb 2006
Reputation Points: 1,471
Solved Threads: 494
@OP
Make a Dialog with a Label (or JTextPane would probably be better), then in the first switch you want to use component.setText("string") . Then, everyplace else you should add text, you want to use component.setText(component.getText() + "string") .
Give that a try, then, if you have problems, come back and post that code, and we will see if we can help you further.
Also, don't forget to add a "\n" to the end of each of those Strings (although I don't believe a Label honors those, but a "
" would work in a Label). Then, maybe, add a short sleep after each text block (if you want to introduce a little pause between each line for effect).
masijade
Industrious Poster
4,253 posts since Feb 2006
Reputation Points: 1,471
Solved Threads: 494