Advertisement
Guest User

Untitled

a guest
May 24th, 2016
72
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.30 KB | None | 0 0
  1. package cursos;
  2.  
  3. import javax.swing.JCheckBox;
  4. import javax.swing.JFrame;
  5. import javax.swing.JPanel;
  6.  
  7. public class Disciplinas {
  8. public static void main(String[] args) {
  9. JFrame frame = new JFrame("Sistemas para Internet");
  10. frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
  11.  
  12. JPanel panel = new JPanel();
  13. JCheckBox dis1 = new JCheckBox("Algoritmo");
  14. JCheckBox dis2 = new JCheckBox("Sistemas Operacionais");
  15. JCheckBox dis3 = new JCheckBox("Metodologia e Linguagem de Programação Avançada");
  16. JCheckBox dis4 = new JCheckBox("Analise de Projetos");
  17. JCheckBox dis5 = new JCheckBox("Sistemas de informação");
  18.  
  19. panel.add(dis1);
  20. panel.add(dis2);
  21. panel.add(dis3);
  22. panel.add(dis4);
  23. panel.add(dis5);
  24.  
  25. frame.setContentPane(panel);
  26. frame.setVisible(true);
  27. frame.pack();
  28. }
  29. }
  30.  
  31.  
  32.  
  33.  
  34.  
  35.  
  36.  
  37.  
  38.  
  39.  
  40.  
  41.  
  42.  
  43.  
  44.  
  45. package cursos;
  46.  
  47. import javax.swing.JComboBox;
  48. import javax.swing.JFrame;
  49. import javax.swing.JPanel;
  50.  
  51. public class Cursos {
  52. public static void main(String[] args) {
  53. JFrame frame = new JFrame("Cursos");
  54. frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
  55.  
  56. JPanel panel = new JPanel();
  57. JComboBox<String> box = new JComboBox<String>();
  58.  
  59. box.addItem("Medicina");
  60. box.addItem("Odontologia");
  61. box.addItem("Administração");
  62. box.addItem("Contabilidade");
  63. box.addItem("Psicologia");
  64.  
  65. panel.add(box);
  66.  
  67. frame.setContentPane(panel);
  68. frame.setVisible(true);
  69. frame.pack();
  70. }
  71.  
  72. }
  73.  
  74.  
  75.  
  76.  
  77.  
  78.  
  79.  
  80.  
  81.  
  82.  
  83.  
  84.  
  85.  
  86.  
  87.  
  88.  
  89.  
  90.  
  91.  
  92. package login;
  93.  
  94. import javax.swing.JButton;
  95. import javax.swing.JFrame;
  96. import javax.swing.JLabel;
  97. import javax.swing.JPanel;
  98. import javax.swing.JPasswordField;
  99. import javax.swing.JTextField;
  100.  
  101. public class Login {
  102. public static void main(String[] args) {
  103.  
  104. JFrame frame = new JFrame("Login");
  105. frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
  106.  
  107. JPanel panel = new JPanel();
  108. JLabel user = new JLabel("Login");
  109. JLabel pass = new JLabel("Senha:");
  110. JButton button = new JButton("Entrar");
  111.  
  112. JTextField userData = new JTextField(20);
  113. JPasswordField passData = new JPasswordField(10);
  114.  
  115. panel.add(user);
  116. panel.add(userData);
  117. panel.add(pass);
  118. panel.add(passData);
  119. panel.add(button);
  120.  
  121. frame.setContentPane(panel);
  122. frame.setVisible(true);
  123. frame.pack();
  124. }
  125. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement