Originally Posted by
tanha
As I put the link, I have the LoginForm.java, which is not directly JFrame, but at the runtime, it creates a Form and asking for username and password,
and then I create a new Jframe Form, and named it DictionaryForm.java.
and in the LoginForm.java, if the username and password is correct it display a message, but I need it displays the DictionaryForm.java instead, and also the LoginForm.java should be closed.
I dont know what to do?
Originally Posted by earlierPost
public class LoginForm extends JFrame
sure looks like a JFrame to me ..
what you can do (and I'm not saying it's the most elegant or efficiƫnt way, just got to work here

)
in the LoginForm.java, you add the line
to that part of the if-structure where the login succeeds
on the place where you call the loginFrame, you check wether or not it is still "active", or "visible", or you place a trigger in your LoginFrame.java, right before the dispose(), and after this checks out, you call the DictionaryForm