0
我有一個帶有動作處理程序的jFrame表單,該動作處理程序實例化一個新表單並使用setVisible(true)切換到該表單。這很有效。在Netbeans創建的jFrame表單中找不到setVisible()
當我嘗試調用setVisible(假)在目前的形式,但是,我得到一個錯誤:
cannot find symbol
symbol: method setVisible(boolean)
location: class foo.bar
----
我的操作處理程序是這樣的:
public void Login() {
//#TODO Log in code
setVisible(false); // <-- Error here
mainPage.mainScreen ms = new mainPage.mainScreen();
ms.setVisible(true);
}
你能提供一個SSCCE http://sscce.org/ –