Welcome to JavaRanch
Please use the code button (below the message window) when quoting code; I have added code tags so you can see how much easier it is to read the code.
You have a major error, that you are declaring a local variable called aButton, so the field "aButton" is shadowed.
You also haven't got anything about removing buttons in the actionPerformed method.
Despite many books using that syntax, "addActionListener(this)" is usually bad object-oriented programming. I have written about it
here and
on this old thread which has recently reappeared. This appears to be an applet-specific topic, and I think you might get more answers if I transfer it to the
Applets forum.