-
Notifications
You must be signed in to change notification settings - Fork 9
Expand file tree
/
Copy pathEmployeeDetails.java
More file actions
54 lines (41 loc) · 990 Bytes
/
EmployeeDetails.java
File metadata and controls
54 lines (41 loc) · 990 Bytes
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
43
44
45
46
47
48
49
50
51
52
53
54
import java.awt.*;
import javax.swing.*;
public class EmployeeDetails {
static JTextField t1,t2,t3;
EmployeeDetails()
{
JFrame J = new JFrame("Employees Details");
JLabel l1 = new JLabel("Emp_id: ");
l1.setBounds(100, 100, 200, 30);
t1 = new JTextField();
t1.setBounds(350,100,400,30);
JLabel l2 = new JLabel("Name: ");
l2.setBounds(100, 180, 200, 30);
t2 = new JTextField();
t2.setBounds(350,180,400,30);
JLabel l3 = new JLabel("Salary: ");
l3.setBounds(100, 260, 200, 30);
t3 = new JTextField();
t3.setBounds(350,260,400,30);
JButton B = new JButton("Submit");
B.setBounds(200, 350, 100, 30);
JButton B1 = new JButton("Show");
B1.setBounds(400, 350, 100, 30);
J.add(l1);
J.add(t1);
J.add(l2);
J.add(t2);
J.add(l3);
J.add(t3);
J.add(B);
J.add(B1);
J.setLayout(null);
J.setSize(800,600);
J.setVisible(true);
J.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
}
public static void main(String args[])
{
new EmployeeDetails();
}
}