-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathWithdraw.java
42 lines (42 loc) · 1.55 KB
/
Withdraw.java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
package BankManagementSystem;
import javax.swing.JButton;
import javax.swing.JFrame;
import javax.swing.JLabel;
import javax.swing.JTextField;
import java.awt.Container;
import java.awt.Font;
public class Withdraw implements Runnable{
@Override
public void run(){
JFrame frame=new JFrame("Bank Management System");
Container container=frame.getContentPane();
container.setLayout(null);
frame.setExtendedState(JFrame.MAXIMIZED_BOTH);
frame.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
JLabel label=new JLabel("Withdraw");
label.setBounds(100,50,300,30);
label.setFont(new Font("Consolas",Font.ITALIC,30));
JLabel nameLabel=new JLabel("Enter Amount");
nameLabel.setFont(new Font("Consolas",Font.ITALIC,30));
nameLabel.setBounds(100,100,250,30);
container.add(nameLabel);
JTextField nameTextField=new JTextField();
nameTextField.setFont(new Font("Consolas",Font.ITALIC,20));
nameTextField.setBounds(350,100,80,30);
container.add(nameTextField);
JButton submit=new JButton("Submit");
submit.setFocusPainted(false);
submit.addActionListener(e->frame.dispose());
submit.setBounds(100,150,100,30);
submit.setFont(new Font("Consolas",Font.ITALIC,18));
container.add(submit);
container.add(label);
frame.setResizable(false);
frame.setVisible(true);
try{
Thread.sleep(30000L);
}
catch(InterruptedException ignored){}
frame.dispose();
}
}