create a JFrame and show it----> 显示一个窗口
call the window's setVisible(false) and dispose()--->窗口关掉.
Others you have to use event. But the above is enough.
call the window's setVisible(false) and dispose()--->窗口关掉.
Others you have to use event. But the above is enough.
可以用一个timer,到某个时间调用JFrame的句柄如上面老兄那样关闭窗口