Results 1 to 2 of 2
- 06-27-2007, 04:57 AM #1
Senior Member
- Join Date
- Jun 2007
- Posts
- 132
- Rep Power
- 0
problems with jDialog in a JFrame
I have a JFrame in which when I click in JButton appears a JDialog.
The problem is that doesn’t do anything when I click register button
my code is:
thanksJava Code:public class recordpage extends JDialog{ private Container contain; private JLabel Nick, Pass, ConfimPass, Mail; private JTextField textNick, textMail; private JPasswordField textPass, textConfirmPass; private JButton register; public recordpage (){ super(); Container contain =getContentPane(); contain.setLayout(new FlowLayout()); JLabel Nick =new JLabel("Nick "); JLabel Pass =new JLabel ("password "); JLabel ConfimPass new JLabel ("Confirm your password"); JLabel Mail =new JLabel ("your email: "); JTextField textNick =new JTextField ("", 10); JPasswordField textPass =new JPasswordField("", 10); JPasswordField textConfirmPass=new JPasswordField("", 10); JTextField textMail =new JTextField("", 10); JButton register=new JButton ("Log in"); contain.add(Nick); contain.add(textNick); contain.add(Pass); contain.add(textPass); contain.add(ConfirmPass); contain.add(textConfirmPass); contain.add(Mail); contain.add(textMail); contain.add(register); this.setTitle("Register"); this.setModal(true); this.setLocation(200, 150); this.setSize(new Dimension(300, 180)); this.setVisible(true); registrar.addActionListener ( new ActionListener(){ public void actionPerformed(ActionEvent ae){ dispose(); } } ); } }
- 07-05-2007, 04:14 AM #2
Senior Member
- Join Date
- Jun 2007
- Posts
- 130
- Rep Power
- 0
Similar Threads
-
[SOLVED] How to make a JDialog scrolling from one position to the other.
By Eranga in forum AWT / SwingReplies: 1Last Post: 03-28-2008, 10:26 AM -
help with jdialog
By leonard in forum AWT / SwingReplies: 1Last Post: 08-05-2007, 05:37 AM -
Close a JDialog Programmatically
By Marcus in forum Advanced JavaReplies: 1Last Post: 07-06-2007, 04:06 PM -
Help with JFrame
By Albert in forum AWT / SwingReplies: 2Last Post: 07-04-2007, 04:44 AM -
How to get rid of minimize and close icon on a jdialog?
By sandor in forum AWT / SwingReplies: 1Last Post: 04-09-2007, 12:05 AM


LinkBack URL
About LinkBacks
Reply With Quote
Bookmarks