I am creating a small application using AWT. When I try to close the window, the \"close\" button doesn\'t work.
Here\'s my code:
import java.awt.*;
You could do it like this:
f.addWindowListener(new WindowAdapter(){ public void windowClosing(WindowEvent we){ System.exit(0); } });