i need to close my applications current window without switching off the entire application my code is as follows to set a window visible but it closes all the windows whatever are currently open when i click on the right upper corner red cross button
private void lb_helpMouseClicked(java.awt.event.MouseEvent evt) {
new Reports().setVisible(true);
}
private void lb_certMouseClicked(java.awt.event.MouseEvent evt) {
new ChooseCert().setVisible(true);
}
private void lb_reportMouseClicked(java.awt.event.MouseEvent evt) {
new Reports().setVisible(true);
}
After that just call the appropriate methods.