Reputation: 11
Hi I'm new to NetBeans IDE. I have developed a basic desktop application with two textFields, one for userName
and one for password
. It also has an OK-Button. This app checks the username and password from the database.
Now I have added a Master/Detail sample form to that packet. Now the application works like this: it checks the userName and password when you click the OK button. If correct it runs the CRUD-app and here is where I experience a problem: the Master/Detail sample form runs and does not show on the screen. My question is how do I make it Visible?
Okay- I have created ths to call the CRUD-app which I named BB:
OK.addActionListener(new ActionListener(){
BB call= new BB();//Here I call the crude
It is: public class BB extents Jpanel{// class name
And I did try to use BB.show(); an I got an error saying: non static mrthod show() cannot be referenced fron a static cotext. Even setVisible(true) doesn't show tha application
Upvotes: 0
Views: 630
Reputation: 12883
Your example...
BB call= new BB();//Here I call the crude
Call.setVisible(true);
Did you copy and paste it or type it in? If you copied it, your problem is that you're not calling setVisible
the right object. It should be...
BB call= new BB();
call.setVisible(true); // Notice 'c' instead of 'C'
If that's not the problem, then what class does BB extend? So, in the file BB.java there should be a line like this...
public class BB extends ???
Near the top of the file. What comes after the word extends
in your file?
Upvotes: 1